You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TLDR: The beforeAll method still runs on a Fixture defined in a suite that is excluded via junit Category.
I would like to use a reusable suite local fixture to setup some external state for some integration tests. However, when I filter/exclude all tests in the test suite with either .ignore or --exclude-categories the Fixture's beforeAll method is still called.
Of note, @munit.IgnoreSuite does successfully prevent the Fixture from running.
Reproduction README copy and pasted below:
This repo is a little reproduction of an munit issue.
A reusable Fixture's beforeAll method runs even when it's defining suite is excluded via --exclude-categories=.
Consider the following test file:
The test suite MySuite is annotated with a junit Category.
Which allows us to include or exclude whole test suites.
When we exclude MySuite the tests are skipped but the Fixture's beforeAll method still runs:
Reproduction: https://github.com/valencik/munit-fixture-suite-filtering
TLDR: The
beforeAll
method still runs on aFixture
defined in a suite that is excluded via junit Category.I would like to use a reusable suite local fixture to setup some external state for some integration tests. However, when I filter/exclude all tests in the test suite with either
.ignore
or--exclude-categories
the Fixture'sbeforeAll
method is still called.Of note,
@munit.IgnoreSuite
does successfully prevent the Fixture from running.Reproduction README copy and pasted below:
This repo is a little reproduction of an munit issue.
A reusable Fixture's
beforeAll
method runs even when it's defining suite is excluded via--exclude-categories=
.Consider the following test file:
Within an sbt shell,
test
yields the following, as expected:The test suite MySuite is annotated with a junit Category.
Which allows us to include or exclude whole test suites.
When we exclude MySuite the tests are skipped but the Fixture's
beforeAll
method still runs:testOnly -- --exclude-categories=example.Slow
yields:The text was updated successfully, but these errors were encountered: