Context
- The pretty printer displays
describes with identical names as separate lists in the test report
- This does not match the behaviour of Jest
- Grouping is useful as it allows for the
describe.each({"case1", "case2"}), describe("case1") pattern to test common and distinct functionality for certain cases of (usually) an enum used to switch between logic in a commonised function
Scope
todo: scope this properly. Possible implementations given below for guidance
There are two possible implementations that would work here:
- Update only the pretty printer to group describes
- This is my preferred approach
- Update the test runner to group describes
- This is very edge-casey. We would need to see how jest handles e.g. lifecycle hooks defined in two different describes with the same name
Acceptance criteria
- The pretty printer displays tests and test suites from describe blocks with identical names grouped together
Context
describes with identical names as separate lists in the test reportdescribe.each({"case1", "case2"}),describe("case1")pattern to test common and distinct functionality for certain cases of (usually) an enum used to switch between logic in a commonised functionScope
todo: scope this properly. Possible implementations given below for guidance
There are two possible implementations that would work here:
Acceptance criteria