Skip to content

Commit

Permalink
Use case in names of default reporters
Browse files Browse the repository at this point in the history
  • Loading branch information
horenmar committed Nov 10, 2021
1 parent 62d8913 commit 6603f1d
Show file tree
Hide file tree
Showing 7 changed files with 150 additions and 150 deletions.
12 changes: 6 additions & 6 deletions src/catch2/internal/catch_reporter_registry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ namespace Catch {
ReporterRegistry::ReporterRegistry() {
// Because it is impossible to move out of initializer list,
// we have to add the elements manually
m_factories["automake"] = Detail::make_unique<ReporterFactory<AutomakeReporter>>();
m_factories["Automake"] = Detail::make_unique<ReporterFactory<AutomakeReporter>>();
m_factories["compact"] = Detail::make_unique<ReporterFactory<CompactReporter>>();
m_factories["console"] = Detail::make_unique<ReporterFactory<ConsoleReporter>>();
m_factories["junit"] = Detail::make_unique<ReporterFactory<JunitReporter>>();
m_factories["sonarqube"] = Detail::make_unique<ReporterFactory<SonarQubeReporter>>();
m_factories["tap"] = Detail::make_unique<ReporterFactory<TAPReporter>>();
m_factories["teamcity"] = Detail::make_unique<ReporterFactory<TeamCityReporter>>();
m_factories["xml"] = Detail::make_unique<ReporterFactory<XmlReporter>>();
m_factories["JUnit"] = Detail::make_unique<ReporterFactory<JunitReporter>>();
m_factories["SonarQube"] = Detail::make_unique<ReporterFactory<SonarQubeReporter>>();
m_factories["TAP"] = Detail::make_unique<ReporterFactory<TAPReporter>>();
m_factories["TeamCity"] = Detail::make_unique<ReporterFactory<TeamCityReporter>>();
m_factories["XML"] = Detail::make_unique<ReporterFactory<XmlReporter>>();
}

ReporterRegistry::~ReporterRegistry() = default;
Expand Down
36 changes: 18 additions & 18 deletions tests/SelfTest/Baselines/compact.sw.approved.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1311,19 +1311,19 @@ Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fak
1 [fakeTag]
1 tag

" contains: "fakeTag" with 1 message: 'Tested reporter: automake'
" contains: "fakeTag" with 1 message: 'Tested reporter: Automake'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fake reporter"s) for: "Available reporters:
fake reporter: fake description

" contains: "fake reporter" with 1 message: 'Tested reporter: automake'
" contains: "fake reporter" with 1 message: 'Tested reporter: Automake'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring( "fake test name"s ) && ContainsSubstring( "fakeTestTag"s ) for: "All available test cases:
fake test name
[fakeTestTag]
1 test case

" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: automake'
" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: Automake'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fakeTag"s) for: "All available tags:
1 [fakeTag]
Expand Down Expand Up @@ -1366,78 +1366,78 @@ All available tags:
1 [fakeTag]
1 tag

" contains: "fakeTag" with 1 message: 'Tested reporter: junit'
" contains: "fakeTag" with 1 message: 'Tested reporter: JUnit'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fake reporter"s) for: "<?xml version="1.0" encoding="UTF-8"?>
Available reporters:
fake reporter: fake description

" contains: "fake reporter" with 1 message: 'Tested reporter: junit'
" contains: "fake reporter" with 1 message: 'Tested reporter: JUnit'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring( "fake test name"s ) && ContainsSubstring( "fakeTestTag"s ) for: "<?xml version="1.0" encoding="UTF-8"?>
All available test cases:
fake test name
[fakeTestTag]
1 test case

" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: junit'
" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: JUnit'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fakeTag"s) for: "<?xml version="1.0" encoding="UTF-8"?>
All available tags:
1 [fakeTag]
1 tag

" contains: "fakeTag" with 1 message: 'Tested reporter: sonarqube'
" contains: "fakeTag" with 1 message: 'Tested reporter: SonarQube'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fake reporter"s) for: "<?xml version="1.0" encoding="UTF-8"?>
Available reporters:
fake reporter: fake description

" contains: "fake reporter" with 1 message: 'Tested reporter: sonarqube'
" contains: "fake reporter" with 1 message: 'Tested reporter: SonarQube'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring( "fake test name"s ) && ContainsSubstring( "fakeTestTag"s ) for: "<?xml version="1.0" encoding="UTF-8"?>
All available test cases:
fake test name
[fakeTestTag]
1 test case

" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: sonarqube'
" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: SonarQube'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fakeTag"s) for: "All available tags:
1 [fakeTag]
1 tag

" contains: "fakeTag" with 1 message: 'Tested reporter: tap'
" contains: "fakeTag" with 1 message: 'Tested reporter: TAP'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fake reporter"s) for: "Available reporters:
fake reporter: fake description

" contains: "fake reporter" with 1 message: 'Tested reporter: tap'
" contains: "fake reporter" with 1 message: 'Tested reporter: TAP'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring( "fake test name"s ) && ContainsSubstring( "fakeTestTag"s ) for: "All available test cases:
fake test name
[fakeTestTag]
1 test case

" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: tap'
" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: TAP'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fakeTag"s) for: "All available tags:
1 [fakeTag]
1 tag

" contains: "fakeTag" with 1 message: 'Tested reporter: teamcity'
" contains: "fakeTag" with 1 message: 'Tested reporter: TeamCity'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fake reporter"s) for: "Available reporters:
fake reporter: fake description

" contains: "fake reporter" with 1 message: 'Tested reporter: teamcity'
" contains: "fake reporter" with 1 message: 'Tested reporter: TeamCity'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring( "fake test name"s ) && ContainsSubstring( "fakeTestTag"s ) for: "All available test cases:
fake test name
[fakeTestTag]
1 test case

" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: teamcity'
" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: TeamCity'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fakeTag"s) for: "<?xml version="1.0" encoding="UTF-8"?>
<TagsFromMatchingTests>
Expand All @@ -1447,15 +1447,15 @@ Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fak
<Alias>fakeTag</Alias>
</Aliases>
</Tag>
</TagsFromMatchingTests>" contains: "fakeTag" with 1 message: 'Tested reporter: xml'
</TagsFromMatchingTests>" contains: "fakeTag" with 1 message: 'Tested reporter: XML'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring("fake reporter"s) for: "<?xml version="1.0" encoding="UTF-8"?>
<AvailableReporters>
<Reporter>
<Name>fake reporter</Name>
<Description>fake description</Description>
</Reporter>
</AvailableReporters>" contains: "fake reporter" with 1 message: 'Tested reporter: xml'
</AvailableReporters>" contains: "fake reporter" with 1 message: 'Tested reporter: XML'
Reporters.tests.cpp:<line number>: passed: !(factories.empty()) for: !false
Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring( "fake test name"s ) && ContainsSubstring( "fakeTestTag"s ) for: "<?xml version="1.0" encoding="UTF-8"?>
<MatchingTests>
Expand All @@ -1468,7 +1468,7 @@ Reporters.tests.cpp:<line number>: passed: listingString, ContainsSubstring( "fa
<Line>123456789</Line>
</SourceInfo>
</TestCase>
</MatchingTests>" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: xml'
</MatchingTests>" ( contains: "fake test name" and contains: "fakeTestTag" ) with 1 message: 'Tested reporter: XML'
Reporters.tests.cpp:<line number>: passed:
Message.tests.cpp:<line number>: passed: with 1 message: 'this is a success'
Message.tests.cpp:<line number>: passed:
Expand Down
Loading

0 comments on commit 6603f1d

Please sign in to comment.