spec icon indicating copy to clipboard operation
spec copied to clipboard

fix: cursor and newline missing when running without --watch

Open bartekpacia opened this issue 2 years ago • 2 comments
trafficstars

Fixes #46

Changes proposed

Apparently the finally block containing VT100.showCursor and VT100.newline was not executed because the function was being returned from within the try block.

Now it's fixed. I didn't write tests for it because I'm not familiar with this project's codebase at all.

Check List (Check all the applicable boxes)

  • [x] My code follows the code style of this project.
  • [x] This PR does not contain plagiarized content.
  • [x] The title and description of the PR is clear and explains the approach.

bartekpacia avatar Feb 08 '23 01:02 bartekpacia

Thanks!

rrousselGit avatar Feb 08 '23 10:02 rrousselGit

Do you mind writing a test for this?

As an example, you can look at summary contains list of all errors independently from suites/groups within spec_cli_test.dart. This should give you enough clues for what to do.

You might have to change TestRenderer (cf the testRenderer variable`) to optionally disable the ANSI removal from the output (line 88 in test/utils.dart)

rrousselGit avatar Mar 08 '23 12:03 rrousselGit