catchorg / catchorg/Catch2

Question: how to create a test hiearchy from multiple files?

Open
#2,010 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
21.5k
Forks
3.5k
Avg merge
3d 16h
Merged PRs (30d)
2

Description

I'm creating a hiearchy using nested sections to group tests together in Visual Studio, but sections in multiple files can't have the same name. What's the correct way of doing this? or am I stuck having all the tests in one file?

````
TEST_CASE("SomeBigModule")
{
SECTION("SomeGrouping")
{
SECTION("SomeSubGroupPerFile")
{
SECTION("MyActualTest1") {}
SECTION("MyActualTest2") {}
}
}
}
````

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.