beforeEach does not fire in recursive fashion for nested suites

Description

If I have a test case that looks like this:

I would expect beforeEach to be executed twice - once before each "it" example is run to ensure my component is in a known state before I run that test. This is inline with how other BDD testing frameworks such as Mocha (Javascript) and RSpec (Ruby) work.

The rationale is that you can “describe” the component, then “describe” each function and each “it” within that function will have the component at the clean state if you have a beforeEach at the component level.

With the current TestBox behaviour I either have to duplicate my component setup in a beforeEach within the nested describe, or flatten my test to only have a single level for all methods.

For example, see how Mocha runs a similar test to this: https://www.refheap.com/4631bf3383d61a9785f151802

Assignee

Luis Majano

Reporter

Marcin Szczepanski

Labels

None

Components

Fix versions

Affects versions

Priority

Major
Configure