-2

When I run my Cypress-tests in my terminal, then I care barely read the text. I like having a dark theme (and I think I'm not alone about this). But none of the themes I can find, has an output of the Cypress-run-command, that can be (easily) read.

I'm using the terminal Kitty on my Mac. I've tried several themes, and for all the dark ones, the text is virtually unreadable (see the bottom of this post for examples).

I can read here: Cypress CLI console output not very readable, that it is because Cypress is using ANSI-colors. And I can disable the colors by writing: NO_COLOR=1 npx cypress run.

But I'm not interested in disabling them, I would rather fix them.

And okay, it's better to have no color and be able to read it. But that again means that I need to remember that extra part of the command, every time I run Cypress in my terminal, which is quite the nuisance.

I'm using Cypress across several projects, which all has make-targets with Cypress-commands, which means a lot of places, to add this extra part of the command.

Makefile (before)

cypress-run-development: ## Runs Cypress locally
    npm run cypress:run:development --prefix test/e2e

Makefile (after)

cypress-run-development: ## Runs Cypress locally
    NO_COLORS=1 npm run cypress:run:development --prefix test/e2e

Question summed up

Question 1: Can I really not fix the colors, somehow?
... Disable ANSI, change the output colors, whatever it takes?

Question 2: If I can't fix the colors, can I then set this NO_COLORS via my cypress.config.js-file? ... so I don't need to do this a billion times?


Examples

1984 Light: (Fine)

1984 Light

Adwaita Dark: (Bad)

Awaita Dark

Solarized Dark: (Bad)

Solarized dark

Tokyo Night: (Bad)

Tokyo Night

... And I tried many many more. Same result. All bad for dark colors.

Zeth
  • 2,273
  • 4
  • 43
  • 91

0 Answers0