mirror of
https://github.com/catchorg/Catch2.git
synced 2025-08-02 13:25:41 +02:00
Integrate the new reporter specs into Catch2
This means that the CLI interface now uses the new key-value oriented reporter spec, the common reporter base creates the colour implementation based on the reporter-specific configuration, and it also stores the custom configuration options for each reporter instance. Closes #339 as it allows per-reporter forcing of ansi colour codes.
This commit is contained in:
@@ -1316,10 +1316,8 @@ CmdLine.tests.cpp:<line number>: passed: config.abortAfter == -1 for: -1 == -1
|
||||
CmdLine.tests.cpp:<line number>: passed: config.noThrow == false for: false == false
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications.empty() for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: !(cfg.hasTestFilters()) for: !false
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReportersAndOutputFiles().size() == 1 for: 1 == 1
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} } for: { console, <default-output> }
|
||||
==
|
||||
{ console, <default-output> }
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReporterSpecs().size() == 1 for: 1 == 1
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} } for: {?} == {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.hasTestFilters() for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.testSpec().matches(*fakeTestCase("notIncluded")) == false for: false == false
|
||||
@@ -1333,37 +1331,21 @@ CmdLine.tests.cpp:<line number>: passed: cfg.hasTestFilters() for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.testSpec().matches(*fakeTestCase("test1")) == false for: false == false
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.testSpec().matches(*fakeTestCase("alwaysIncluded")) for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} } for: { { console, <default-output> } }
|
||||
==
|
||||
{ { console, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} } for: { { xml, <default-output> } }
|
||||
==
|
||||
{ { xml, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} } for: { { junit, <default-output> } }
|
||||
==
|
||||
{ { junit, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: !result for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result.errorMessage(), ContainsSubstring("Unrecognized reporter") for: "Unrecognized reporter, 'unsupported'. Check available with --list-reporters" contains: "Unrecognized reporter"
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} } for: { { console, out.txt } }
|
||||
==
|
||||
{ { console, out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} } for: { { console, C:\Temp\out.txt } }
|
||||
==
|
||||
{ { console, C:\Temp\out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: !result for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result.errorMessage(), ContainsSubstring("empty filename") for: "Reporter 'console' has empty filename specified as its output. Supply a filename or remove the colons to use the default output." contains: "empty filename"
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} } for: { { xml, output.xml }, { junit, output-junit.xml } }
|
||||
==
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} } for: { { xml, output.xml }, { console, <default-output> } }
|
||||
==
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
CmdLine.tests.cpp:<line number>: passed: !result for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result.errorMessage(), ContainsSubstring("Only one reporter may have unspecified output file.") for: "Only one reporter may have unspecified output file." contains: "Only one reporter may have unspecified output file."
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({"test", "-b"}) for: {?}
|
||||
|
@@ -1314,10 +1314,8 @@ CmdLine.tests.cpp:<line number>: passed: config.abortAfter == -1 for: -1 == -1
|
||||
CmdLine.tests.cpp:<line number>: passed: config.noThrow == false for: false == false
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications.empty() for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: !(cfg.hasTestFilters()) for: !false
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReportersAndOutputFiles().size() == 1 for: 1 == 1
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} } for: { console, <default-output> }
|
||||
==
|
||||
{ console, <default-output> }
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReporterSpecs().size() == 1 for: 1 == 1
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} } for: {?} == {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.hasTestFilters() for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.testSpec().matches(*fakeTestCase("notIncluded")) == false for: false == false
|
||||
@@ -1331,37 +1329,21 @@ CmdLine.tests.cpp:<line number>: passed: cfg.hasTestFilters() for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.testSpec().matches(*fakeTestCase("test1")) == false for: false == false
|
||||
CmdLine.tests.cpp:<line number>: passed: cfg.testSpec().matches(*fakeTestCase("alwaysIncluded")) for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} } for: { { console, <default-output> } }
|
||||
==
|
||||
{ { console, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} } for: { { xml, <default-output> } }
|
||||
==
|
||||
{ { xml, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} } for: { { junit, <default-output> } }
|
||||
==
|
||||
{ { junit, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: !result for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result.errorMessage(), ContainsSubstring("Unrecognized reporter") for: "Unrecognized reporter, 'unsupported'. Check available with --list-reporters" contains: "Unrecognized reporter"
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} } for: { { console, out.txt } }
|
||||
==
|
||||
{ { console, out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} } for: { { console, C:\Temp\out.txt } }
|
||||
==
|
||||
{ { console, C:\Temp\out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: !result for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result.errorMessage(), ContainsSubstring("empty filename") for: "Reporter 'console' has empty filename specified as its output. Supply a filename or remove the colons to use the default output." contains: "empty filename"
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} } for: { { xml, output.xml }, { junit, output-junit.xml } }
|
||||
==
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} } for: { { xml, output.xml }, { console, <default-output> } }
|
||||
==
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" }) for: {?}
|
||||
CmdLine.tests.cpp:<line number>: passed: config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
CmdLine.tests.cpp:<line number>: passed: !result for: true
|
||||
CmdLine.tests.cpp:<line number>: passed: result.errorMessage(), ContainsSubstring("Only one reporter may have unspecified output file.") for: "Only one reporter may have unspecified output file." contains: "Only one reporter may have unspecified output file."
|
||||
CmdLine.tests.cpp:<line number>: passed: cli.parse({"test", "-b"}) for: {?}
|
||||
|
@@ -1396,5 +1396,5 @@ due to unexpected exception with message:
|
||||
|
||||
===============================================================================
|
||||
test cases: 390 | 314 passed | 69 failed | 7 failed as expected
|
||||
assertions: 2225 | 2070 passed | 128 failed | 27 failed as expected
|
||||
assertions: 2223 | 2068 passed | 128 failed | 27 failed as expected
|
||||
|
||||
|
@@ -9433,16 +9433,14 @@ with expansion:
|
||||
!false
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cfg.getReportersAndOutputFiles().size() == 1 )
|
||||
CHECK( cfg.getReporterSpecs().size() == 1 )
|
||||
with expansion:
|
||||
1 == 1
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} } )
|
||||
CHECK( cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} } )
|
||||
with expansion:
|
||||
{ console, <default-output> }
|
||||
==
|
||||
{ console, <default-output> }
|
||||
{?} == {?}
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
@@ -9544,11 +9542,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { console, <default-output> } }
|
||||
==
|
||||
{ { console, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9568,11 +9564,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { xml, <default-output> } }
|
||||
==
|
||||
{ { xml, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9592,11 +9586,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { junit, <default-output> } }
|
||||
==
|
||||
{ { junit, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9635,11 +9627,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } } )
|
||||
with expansion:
|
||||
{ { console, out.txt } }
|
||||
==
|
||||
{ { console, out.txt } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9659,34 +9649,12 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } } )
|
||||
with expansion:
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
==
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
reporter
|
||||
Output file cannot be empty
|
||||
-------------------------------------------------------------------------------
|
||||
CmdLine.tests.cpp:<line number>
|
||||
...............................................................................
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( !result )
|
||||
with expansion:
|
||||
true
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE_THAT( result.errorMessage(), ContainsSubstring("empty filename") )
|
||||
with expansion:
|
||||
"Reporter 'console' has empty filename specified as its output. Supply a
|
||||
filename or remove the colons to use the default output." contains: "empty
|
||||
filename"
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
reporter
|
||||
@@ -9697,16 +9665,14 @@ CmdLine.tests.cpp:<line number>
|
||||
...............................................................................
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" }) )
|
||||
CHECK( cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" }) )
|
||||
with expansion:
|
||||
{?}
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } } )
|
||||
with expansion:
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
==
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
@@ -9718,16 +9684,14 @@ CmdLine.tests.cpp:<line number>
|
||||
...............................................................................
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" }) )
|
||||
CHECK( cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" }) )
|
||||
with expansion:
|
||||
{?}
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
==
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
@@ -17953,5 +17917,5 @@ Misc.tests.cpp:<line number>: PASSED:
|
||||
|
||||
===============================================================================
|
||||
test cases: 390 | 300 passed | 83 failed | 7 failed as expected
|
||||
assertions: 2240 | 2070 passed | 143 failed | 27 failed as expected
|
||||
assertions: 2238 | 2068 passed | 143 failed | 27 failed as expected
|
||||
|
||||
|
@@ -9431,16 +9431,14 @@ with expansion:
|
||||
!false
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cfg.getReportersAndOutputFiles().size() == 1 )
|
||||
CHECK( cfg.getReporterSpecs().size() == 1 )
|
||||
with expansion:
|
||||
1 == 1
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} } )
|
||||
CHECK( cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} } )
|
||||
with expansion:
|
||||
{ console, <default-output> }
|
||||
==
|
||||
{ console, <default-output> }
|
||||
{?} == {?}
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
@@ -9542,11 +9540,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { console, <default-output> } }
|
||||
==
|
||||
{ { console, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9566,11 +9562,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { xml, <default-output> } }
|
||||
==
|
||||
{ { xml, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9590,11 +9584,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { junit, <default-output> } }
|
||||
==
|
||||
{ { junit, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9633,11 +9625,9 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } } )
|
||||
with expansion:
|
||||
{ { console, out.txt } }
|
||||
==
|
||||
{ { console, out.txt } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
@@ -9657,34 +9647,12 @@ with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } } )
|
||||
with expansion:
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
==
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
{ {?} } == { {?} }
|
||||
with message:
|
||||
result.errorMessage() := ""
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
reporter
|
||||
Output file cannot be empty
|
||||
-------------------------------------------------------------------------------
|
||||
CmdLine.tests.cpp:<line number>
|
||||
...............................................................................
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( !result )
|
||||
with expansion:
|
||||
true
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE_THAT( result.errorMessage(), ContainsSubstring("empty filename") )
|
||||
with expansion:
|
||||
"Reporter 'console' has empty filename specified as its output. Supply a
|
||||
filename or remove the colons to use the default output." contains: "empty
|
||||
filename"
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
reporter
|
||||
@@ -9695,16 +9663,14 @@ CmdLine.tests.cpp:<line number>
|
||||
...............................................................................
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" }) )
|
||||
CHECK( cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" }) )
|
||||
with expansion:
|
||||
{?}
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } } )
|
||||
with expansion:
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
==
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
@@ -9716,16 +9682,14 @@ CmdLine.tests.cpp:<line number>
|
||||
...............................................................................
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
CHECK( cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" }) )
|
||||
CHECK( cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" }) )
|
||||
with expansion:
|
||||
{?}
|
||||
|
||||
CmdLine.tests.cpp:<line number>: PASSED:
|
||||
REQUIRE( config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} } )
|
||||
REQUIRE( config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } } )
|
||||
with expansion:
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
==
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
Process can be configured on command line
|
||||
@@ -17945,5 +17909,5 @@ Misc.tests.cpp:<line number>: PASSED:
|
||||
|
||||
===============================================================================
|
||||
test cases: 390 | 300 passed | 83 failed | 7 failed as expected
|
||||
assertions: 2240 | 2070 passed | 143 failed | 27 failed as expected
|
||||
assertions: 2238 | 2068 passed | 143 failed | 27 failed as expected
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<testsuitesloose text artifact
|
||||
>
|
||||
<testsuite name="<exe-name>" errors="17" failures="126" tests="2240" hostname="tbd" time="{duration}" timestamp="{iso8601-timestamp}">
|
||||
<testsuite name="<exe-name>" errors="17" failures="126" tests="2238" hostname="tbd" time="{duration}" timestamp="{iso8601-timestamp}">
|
||||
<properties>
|
||||
<property name="random-seed" value="1"/>
|
||||
<property name="filters" value="~[!nonportable]~[!benchmark]~[approvals] *"/>
|
||||
@@ -1109,7 +1109,6 @@ Message.tests.cpp:<line number>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/must match one of the available ones" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/With output file" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/With Windows-like absolute path as output file" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Output file cannot be empty" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Multiple reporters/All with output files" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Multiple reporters/Mixed output files and default output" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Multiple reporters/cannot have multiple reporters with default output" time="{duration}" status="run"/>
|
||||
|
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<testsuites>
|
||||
<testsuite name="<exe-name>" errors="17" failures="126" tests="2240" hostname="tbd" time="{duration}" timestamp="{iso8601-timestamp}">
|
||||
<testsuite name="<exe-name>" errors="17" failures="126" tests="2238" hostname="tbd" time="{duration}" timestamp="{iso8601-timestamp}">
|
||||
<properties>
|
||||
<property name="random-seed" value="1"/>
|
||||
<property name="filters" value="~[!nonportable]~[!benchmark]~[approvals] *"/>
|
||||
@@ -1108,7 +1108,6 @@ Message.tests.cpp:<line number>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/must match one of the available ones" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/With output file" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/With Windows-like absolute path as output file" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Output file cannot be empty" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Multiple reporters/All with output files" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Multiple reporters/Mixed output files and default output" time="{duration}" status="run"/>
|
||||
<testcase classname="<exe-name>.global" name="Process can be configured on command line/reporter/Multiple reporters/cannot have multiple reporters with default output" time="{duration}" status="run"/>
|
||||
|
@@ -66,7 +66,6 @@
|
||||
<testCase name="Process can be configured on command line/reporter/must match one of the available ones" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/With output file" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/With Windows-like absolute path as output file" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Output file cannot be empty" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Multiple reporters/All with output files" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Multiple reporters/Mixed output files and default output" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Multiple reporters/cannot have multiple reporters with default output" duration="{duration}"/>
|
||||
|
@@ -65,7 +65,6 @@
|
||||
<testCase name="Process can be configured on command line/reporter/must match one of the available ones" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/With output file" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/With Windows-like absolute path as output file" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Output file cannot be empty" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Multiple reporters/All with output files" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Multiple reporters/Mixed output files and default output" duration="{duration}"/>
|
||||
<testCase name="Process can be configured on command line/reporter/Multiple reporters/cannot have multiple reporters with default output" duration="{duration}"/>
|
||||
|
@@ -2479,9 +2479,9 @@ ok {test-number} - config.reporterSpecifications.empty() for: true
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !(cfg.hasTestFilters()) for: !false
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cfg.getReportersAndOutputFiles().size() == 1 for: 1 == 1
|
||||
ok {test-number} - cfg.getReporterSpecs().size() == 1 for: 1 == 1
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} } for: { console, <default-output> } == { console, <default-output> }
|
||||
ok {test-number} - cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} } for: {?} == {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?}
|
||||
# Process can be configured on command line
|
||||
@@ -2509,15 +2509,15 @@ ok {test-number} - cfg.testSpec().matches(*fakeTestCase("alwaysIncluded")) for:
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} } for: { { console, <default-output> } } == { { console, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} } for: { { xml, <default-output> } } == { { xml, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} } for: { { junit, <default-output> } } == { { junit, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !result for: true
|
||||
# Process can be configured on command line
|
||||
@@ -2525,23 +2525,19 @@ ok {test-number} - result.errorMessage(), ContainsSubstring("Unrecognized report
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} } for: { { console, out.txt } } == { { console, out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} } for: { { console, C:\Temp\out.txt } } == { { console, C:\Temp\out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !result for: true
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" }) for: {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result.errorMessage(), ContainsSubstring("empty filename") for: "Reporter 'console' has empty filename specified as its output. Supply a filename or remove the colons to use the default output." contains: "empty filename"
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" }) for: {?}
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" }) for: {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} } for: { { xml, output.xml }, { junit, output-junit.xml } } == { { xml, output.xml }, { junit, output-junit.xml } }
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" }) for: {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} } for: { { xml, output.xml }, { console, <default-output> } } == { { xml, output.xml }, { console, <default-output> } }
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !result for: true
|
||||
# Process can be configured on command line
|
||||
@@ -4482,5 +4478,5 @@ ok {test-number} - q3 == 23. for: 23.0 == 23.0
|
||||
ok {test-number} -
|
||||
# xmlentitycheck
|
||||
ok {test-number} -
|
||||
1..2240
|
||||
1..2238
|
||||
|
||||
|
@@ -2477,9 +2477,9 @@ ok {test-number} - config.reporterSpecifications.empty() for: true
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !(cfg.hasTestFilters()) for: !false
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cfg.getReportersAndOutputFiles().size() == 1 for: 1 == 1
|
||||
ok {test-number} - cfg.getReporterSpecs().size() == 1 for: 1 == 1
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} } for: { console, <default-output> } == { console, <default-output> }
|
||||
ok {test-number} - cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} } for: {?} == {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?}
|
||||
# Process can be configured on command line
|
||||
@@ -2507,15 +2507,15 @@ ok {test-number} - cfg.testSpec().matches(*fakeTestCase("alwaysIncluded")) for:
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} } for: { { console, <default-output> } } == { { console, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} } for: { { xml, <default-output> } } == { { xml, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} } for: { { junit, <default-output> } } == { { junit, <default-output> } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !result for: true
|
||||
# Process can be configured on command line
|
||||
@@ -2523,23 +2523,19 @@ ok {test-number} - result.errorMessage(), ContainsSubstring("Unrecognized report
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} } for: { { console, out.txt } } == { { console, out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result for: {?} with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} } for: { { console, C:\Temp\out.txt } } == { { console, C:\Temp\out.txt } } with 1 message: 'result.errorMessage() := ""'
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } } for: { {?} } == { {?} } with 1 message: 'result.errorMessage() := ""'
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !result for: true
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" }) for: {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - result.errorMessage(), ContainsSubstring("empty filename") for: "Reporter 'console' has empty filename specified as its output. Supply a filename or remove the colons to use the default output." contains: "empty filename"
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" }) for: {?}
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" }) for: {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} } for: { { xml, output.xml }, { junit, output-junit.xml } } == { { xml, output.xml }, { junit, output-junit.xml } }
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" }) for: {?}
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} } for: { { xml, output.xml }, { console, <default-output> } } == { { xml, output.xml }, { console, <default-output> } }
|
||||
ok {test-number} - config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } } for: { {?}, {?} } == { {?}, {?} }
|
||||
# Process can be configured on command line
|
||||
ok {test-number} - !result for: true
|
||||
# Process can be configured on command line
|
||||
@@ -4474,5 +4470,5 @@ ok {test-number} - q3 == 23. for: 23.0 == 23.0
|
||||
ok {test-number} -
|
||||
# xmlentitycheck
|
||||
ok {test-number} -
|
||||
1..2240
|
||||
1..2238
|
||||
|
||||
|
@@ -11468,7 +11468,7 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cfg.getReportersAndOutputFiles().size() == 1
|
||||
cfg.getReporterSpecs().size() == 1
|
||||
</Original>
|
||||
<Expanded>
|
||||
1 == 1
|
||||
@@ -11476,12 +11476,10 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} }
|
||||
cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ console, <default-output> }
|
||||
==
|
||||
{ console, <default-output> }
|
||||
{?} == {?}
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="9" failures="0" expectedFailures="0"/>
|
||||
@@ -11618,12 +11616,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { console, <default-output> } }
|
||||
==
|
||||
{ { console, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11648,12 +11644,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { xml, <default-output> } }
|
||||
==
|
||||
{ { xml, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11678,12 +11672,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { junit, <default-output> } }
|
||||
==
|
||||
{ { junit, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11730,12 +11722,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} }
|
||||
config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { console, out.txt } }
|
||||
==
|
||||
{ { console, out.txt } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11760,34 +11750,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} }
|
||||
config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
==
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
</Section>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
</Section>
|
||||
<Section name="reporter" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Section name="Output file cannot be empty" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
!result
|
||||
</Original>
|
||||
<Expanded>
|
||||
true
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<Expression success="true" type="REQUIRE_THAT" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
result.errorMessage(), ContainsSubstring("empty filename")
|
||||
</Original>
|
||||
<Expanded>
|
||||
"Reporter 'console' has empty filename specified as its output. Supply a filename or remove the colons to use the default output." contains: "empty filename"
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11799,7 +11765,7 @@ C
|
||||
<Section name="All with output files" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" })
|
||||
cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" })
|
||||
</Original>
|
||||
<Expanded>
|
||||
{?}
|
||||
@@ -11807,12 +11773,10 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} }
|
||||
config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
==
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11826,7 +11790,7 @@ C
|
||||
<Section name="Mixed output files and default output" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" })
|
||||
cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" })
|
||||
</Original>
|
||||
<Expanded>
|
||||
{?}
|
||||
@@ -11834,12 +11798,10 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
==
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -21072,6 +21034,6 @@ loose text artifact
|
||||
</Section>
|
||||
<OverallResult success="true"/>
|
||||
</TestCase>
|
||||
<OverallResults successes="2070" failures="143" expectedFailures="27"/>
|
||||
<OverallResults successes="2068" failures="143" expectedFailures="27"/>
|
||||
<OverallResultsCases successes="300" failures="83" expectedFailures="7"/>
|
||||
</Catch2TestRun>
|
||||
|
@@ -11468,7 +11468,7 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cfg.getReportersAndOutputFiles().size() == 1
|
||||
cfg.getReporterSpecs().size() == 1
|
||||
</Original>
|
||||
<Expanded>
|
||||
1 == 1
|
||||
@@ -11476,12 +11476,10 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cfg.getReportersAndOutputFiles()[0] == Catch::ConfigData::ReporterAndFile{ expectedReporter, {} }
|
||||
cfg.getReporterSpecs()[0] == Catch::ReporterSpec{ expectedReporter, {}, {}, {} }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ console, <default-output> }
|
||||
==
|
||||
{ console, <default-output> }
|
||||
{?} == {?}
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="9" failures="0" expectedFailures="0"/>
|
||||
@@ -11618,12 +11616,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "console", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { console, <default-output> } }
|
||||
==
|
||||
{ { console, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11648,12 +11644,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "xml", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { xml, <default-output> } }
|
||||
==
|
||||
{ { xml, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11678,12 +11672,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "junit", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { junit, <default-output> } }
|
||||
==
|
||||
{ { junit, <default-output> } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11730,12 +11722,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} }
|
||||
config.reporterSpecifications == vec_Specs{ { "console", "out.txt"s, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { console, out.txt } }
|
||||
==
|
||||
{ { console, out.txt } }
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11760,34 +11750,10 @@ C
|
||||
</Info>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} }
|
||||
config.reporterSpecifications == vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
==
|
||||
{ { console, C:\Temp\out.txt } }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
</Section>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
</Section>
|
||||
<Section name="reporter" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Section name="Output file cannot be empty" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
!result
|
||||
</Original>
|
||||
<Expanded>
|
||||
true
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<Expression success="true" type="REQUIRE_THAT" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
result.errorMessage(), ContainsSubstring("empty filename")
|
||||
</Original>
|
||||
<Expanded>
|
||||
"Reporter 'console' has empty filename specified as its output. Supply a filename or remove the colons to use the default output." contains: "empty filename"
|
||||
{ {?} } == { {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11799,7 +11765,7 @@ C
|
||||
<Section name="All with output files" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" })
|
||||
cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" })
|
||||
</Original>
|
||||
<Expanded>
|
||||
{?}
|
||||
@@ -11807,12 +11773,10 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} }
|
||||
config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "junit", "output-junit.xml"s, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
==
|
||||
{ { xml, output.xml }, { junit, output-junit.xml } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -11826,7 +11790,7 @@ C
|
||||
<Section name="Mixed output files and default output" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Expression success="true" type="CHECK" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" })
|
||||
cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" })
|
||||
</Original>
|
||||
<Expanded>
|
||||
{?}
|
||||
@@ -11834,12 +11798,10 @@ C
|
||||
</Expression>
|
||||
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/IntrospectiveTests/CmdLine.tests.cpp" >
|
||||
<Original>
|
||||
config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} }
|
||||
config.reporterSpecifications == vec_Specs{ { "xml", "output.xml"s, {}, {} }, { "console", {}, {}, {} } }
|
||||
</Original>
|
||||
<Expanded>
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
==
|
||||
{ { xml, output.xml }, { console, <default-output> } }
|
||||
{ {?}, {?} } == { {?}, {?} }
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResults successes="2" failures="0" expectedFailures="0"/>
|
||||
@@ -21071,6 +21033,6 @@ There is no extra whitespace here
|
||||
</Section>
|
||||
<OverallResult success="true"/>
|
||||
</TestCase>
|
||||
<OverallResults successes="2070" failures="143" expectedFailures="27"/>
|
||||
<OverallResults successes="2068" failures="143" expectedFailures="27"/>
|
||||
<OverallResultsCases successes="300" failures="83" expectedFailures="7"/>
|
||||
</Catch2TestRun>
|
||||
|
@@ -361,9 +361,9 @@ TEST_CASE( "Process can be configured on command line", "[config][command-line]"
|
||||
#endif
|
||||
;
|
||||
|
||||
CHECK( cfg.getReportersAndOutputFiles().size() == 1 );
|
||||
CHECK( cfg.getReportersAndOutputFiles()[0] ==
|
||||
Catch::ConfigData::ReporterAndFile{ expectedReporter, {} } );
|
||||
CHECK( cfg.getReporterSpecs().size() == 1 );
|
||||
CHECK( cfg.getReporterSpecs()[0] ==
|
||||
Catch::ReporterSpec{ expectedReporter, {}, {}, {} } );
|
||||
}
|
||||
|
||||
SECTION("test lists") {
|
||||
@@ -399,28 +399,31 @@ TEST_CASE( "Process can be configured on command line", "[config][command-line]"
|
||||
}
|
||||
|
||||
SECTION("reporter") {
|
||||
using vec_ReporterAndFile = std::vector<Catch::ConfigData::ReporterAndFile>;
|
||||
using vec_Specs = std::vector<Catch::ReporterSpec>;
|
||||
using namespace std::string_literals;
|
||||
SECTION("-r/console") {
|
||||
auto result = cli.parse({"test", "-r", "console"});
|
||||
CAPTURE(result.errorMessage());
|
||||
CHECK(result);
|
||||
|
||||
REQUIRE(config.reporterSpecifications == vec_ReporterAndFile{ {"console", {}} });
|
||||
REQUIRE( config.reporterSpecifications ==
|
||||
vec_Specs{ { "console", {}, {}, {} } } );
|
||||
}
|
||||
SECTION("-r/xml") {
|
||||
auto result = cli.parse({"test", "-r", "xml"});
|
||||
CAPTURE(result.errorMessage());
|
||||
CHECK(result);
|
||||
|
||||
REQUIRE(config.reporterSpecifications == vec_ReporterAndFile{ {"xml", {}} });
|
||||
REQUIRE( config.reporterSpecifications ==
|
||||
vec_Specs{ { "xml", {}, {}, {} } } );
|
||||
}
|
||||
SECTION("--reporter/junit") {
|
||||
auto result = cli.parse({"test", "--reporter", "junit"});
|
||||
CAPTURE(result.errorMessage());
|
||||
CHECK(result);
|
||||
|
||||
REQUIRE(config.reporterSpecifications == vec_ReporterAndFile{ {"junit", {}} });
|
||||
REQUIRE( config.reporterSpecifications ==
|
||||
vec_Specs{ { "junit", {}, {}, {} } } );
|
||||
}
|
||||
SECTION("must match one of the available ones") {
|
||||
auto result = cli.parse({"test", "--reporter", "unsupported"});
|
||||
@@ -429,34 +432,34 @@ TEST_CASE( "Process can be configured on command line", "[config][command-line]"
|
||||
REQUIRE_THAT(result.errorMessage(), ContainsSubstring("Unrecognized reporter"));
|
||||
}
|
||||
SECTION("With output file") {
|
||||
auto result = cli.parse({ "test", "-r", "console::out.txt" });
|
||||
auto result = cli.parse({ "test", "-r", "console::out=out.txt" });
|
||||
CAPTURE(result.errorMessage());
|
||||
CHECK(result);
|
||||
REQUIRE(config.reporterSpecifications == vec_ReporterAndFile{ {"console", "out.txt"s} });
|
||||
REQUIRE( config.reporterSpecifications ==
|
||||
vec_Specs{ { "console", "out.txt"s, {}, {} } } );
|
||||
}
|
||||
SECTION("With Windows-like absolute path as output file") {
|
||||
auto result = cli.parse({ "test", "-r", "console::C:\\Temp\\out.txt" });
|
||||
auto result = cli.parse({ "test", "-r", "console::out=C:\\Temp\\out.txt" });
|
||||
CAPTURE(result.errorMessage());
|
||||
CHECK(result);
|
||||
REQUIRE(config.reporterSpecifications == vec_ReporterAndFile{ {"console", "C:\\Temp\\out.txt"s} });
|
||||
}
|
||||
SECTION("Output file cannot be empty") {
|
||||
auto result = cli.parse({"test", "--reporter", "console::"});
|
||||
CHECK(!result);
|
||||
|
||||
REQUIRE_THAT(result.errorMessage(), ContainsSubstring("empty filename"));
|
||||
REQUIRE( config.reporterSpecifications ==
|
||||
vec_Specs{ { "console", "C:\\Temp\\out.txt"s, {}, {} } } );
|
||||
}
|
||||
SECTION("Multiple reporters") {
|
||||
SECTION("All with output files") {
|
||||
CHECK(cli.parse({ "test", "-r", "xml::output.xml", "-r", "junit::output-junit.xml" }));
|
||||
REQUIRE(config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"junit", "output-junit.xml"s} });
|
||||
CHECK(cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "junit::out=output-junit.xml" }));
|
||||
REQUIRE( config.reporterSpecifications ==
|
||||
vec_Specs{ { "xml", "output.xml"s, {}, {} },
|
||||
{ "junit", "output-junit.xml"s, {}, {} } } );
|
||||
}
|
||||
SECTION("Mixed output files and default output") {
|
||||
CHECK(cli.parse({ "test", "-r", "xml::output.xml", "-r", "console" }));
|
||||
REQUIRE(config.reporterSpecifications == vec_ReporterAndFile{ {"xml", "output.xml"s}, {"console", {}} });
|
||||
CHECK(cli.parse({ "test", "-r", "xml::out=output.xml", "-r", "console" }));
|
||||
REQUIRE( config.reporterSpecifications ==
|
||||
vec_Specs{ { "xml", "output.xml"s, {}, {} },
|
||||
{ "console", {}, {}, {} } } );
|
||||
}
|
||||
SECTION("cannot have multiple reporters with default output") {
|
||||
auto result = cli.parse({ "test", "-r", "console", "-r", "xml::output.xml", "-r", "junit" });
|
||||
auto result = cli.parse({ "test", "-r", "console", "-r", "xml::out=output.xml", "-r", "junit" });
|
||||
CHECK(!result);
|
||||
REQUIRE_THAT(result.errorMessage(), ContainsSubstring("Only one reporter may have unspecified output file."));
|
||||
}
|
||||
|
@@ -89,7 +89,8 @@ TEST_CASE( "Reporter's write listings to provided stream", "[reporters]" ) {
|
||||
|
||||
Catch::ConfigData config_data;
|
||||
Catch::Config config( config_data );
|
||||
Catch::ReporterConfig rep_config( &config, &sstream );
|
||||
Catch::ReporterConfig rep_config(
|
||||
&config, &sstream, Catch::ColourMode::None, {} );
|
||||
auto reporter = factory.second->create( rep_config );
|
||||
|
||||
DYNAMIC_SECTION( factory.first << " reporter lists tags" ) {
|
||||
@@ -176,7 +177,8 @@ TEST_CASE("Multireporter calls reporters and listeners in correct order",
|
||||
Catch::ConfigData config_data;
|
||||
Catch::Config config( config_data );
|
||||
StringIStream sstream;
|
||||
Catch::ReporterConfig rep_config( &config, &sstream );
|
||||
Catch::ReporterConfig rep_config(
|
||||
&config, &sstream, Catch::ColourMode::None, {} );
|
||||
|
||||
// We add reporters before listeners, to check that internally they
|
||||
// get sorted properly, and listeners are called first anyway.
|
||||
@@ -229,7 +231,8 @@ TEST_CASE("Multireporter updates ReporterPreferences properly",
|
||||
Catch::ConfigData config_data;
|
||||
Catch::Config config( config_data );
|
||||
StringIStream sstream;
|
||||
Catch::ReporterConfig rep_config( &config, &sstream );
|
||||
Catch::ReporterConfig rep_config(
|
||||
&config, &sstream, Catch::ColourMode::None, {} );
|
||||
Catch::MultiReporter multiReporter( &config );
|
||||
|
||||
// Post init defaults
|
||||
|
Reference in New Issue
Block a user