rtfeldman / rtfeldman/node-test-runner

Rerun only failed tests in watch mode

Open
#51 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
JavaScript
Stars
140
Forks
83
Avg merge
8h 25m
Merged PRs (30d)
5

Description

Jacob on Slack had a cool idea, and I'm just gonna screencap it here:

screen shot 2016-06-17 at 1 41 47 pm

Here's a design for how this could work:

  1. We now have the guarantee that each test has a unique description.
  2. We could use this as a unique identifier, and serialize the outcome of all tests to disk after a run. (e.g. {"id": ["top-level describe", "nested describe", "my description"], "passed": true}.)
  3. The next time we detect a watch change, we could diff the new tree of tests against the old one before running. Any test that had passed: true last time, we don't bother re-running this time. (This way, we automatically add any new tests to the mix.)
  4. If the tests we re-ran all passed, then we can go back and re-run all the others to make sure they still pass.
  5. Profit!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files, tests, or entry points are named in the issue. Start by locating the watch-mode implementation and how test outcomes are represented, then trace how a watch change triggers execution. Done means persisted results can identify previously passing tests, rerun failed or new tests first, and run the remaining tests after those pass.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
cli, testing-qa
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.