Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make test output slightly easier to read #24071

Open
kruncher opened this issue Jun 1, 2024 · 3 comments · May be fixed by #24357
Open

Make test output slightly easier to read #24071

kruncher opened this issue Jun 1, 2024 · 3 comments · May be fixed by #24357
Assignees
Labels
cli related to cli/ dir good first issue Good for newcomers suggestion suggestions for new features (yet to be agreed) testing related to deno test and coverage

Comments

@kruncher
Copy link

kruncher commented Jun 1, 2024

At the moment I find the test output difficult to make quick sense of because it takes the following shape:

the test name
  step 1
  step 2
the test name ... ok (1ms)

I would personally find this easier to read if it were formatted as follows instead:

the test name
  step 1
  step 2
  the test name ... ok (1ms)

The below illustrates how it currently looks and an alternative approach where the closing line of the test is also printed darker so that it's easier to scan through the tests:
image
Perhaps the repeat of the test name could be removed entirely?
image

Note: This was originally posted in the Discord channel but re-posting here as requested :)

@iuioiua
Copy link
Collaborator

iuioiua commented Jun 2, 2024

My vote is for option #​2. In cases where a test has many steps, the user would otherwise have to scroll up to identify the test in question.

@dsherret dsherret added the suggestion suggestions for new features (yet to be agreed) label Jun 3, 2024
@lucacasonato lucacasonato added good first issue Good for newcomers cli related to cli/ dir tests related to tests testing related to deno test and coverage and removed tests related to tests labels Jun 7, 2024
@nkaradzhov
Copy link

Hi, I can work on this. Do we have decision on the exact fix?

@iuioiua
Copy link
Collaborator

iuioiua commented Jun 23, 2024

@hukuuu, I've assigned this task to you. I suggest implementing the first approach, as omitting the repeat test name could make things less easy to follow. From there, we can gather feedback from others.

nkaradzhov added a commit to nkaradzhov/deno that referenced this issue Jun 25, 2024
Indent last line of tests that contain multiple steps.
nkaradzhov added a commit to nkaradzhov/deno that referenced this issue Jun 27, 2024
Indent last line of tests that contain multiple steps.
@iuioiua iuioiua linked a pull request Jun 28, 2024 that will close this issue
nkaradzhov added a commit to nkaradzhov/deno that referenced this issue Jun 28, 2024
Indent last line of tests that contain multiple steps.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli related to cli/ dir good first issue Good for newcomers suggestion suggestions for new features (yet to be agreed) testing related to deno test and coverage
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants