struct -> class normalization for reporters

This commit is contained in:
Martin Hořeňovský 2022-04-10 22:03:12 +02:00
parent 195a6ac941
commit 9abe49ec53
No known key found for this signature in database
GPG Key ID: DE48307B8B0D381A
6 changed files with 13 additions and 13 deletions

View File

@ -12,7 +12,8 @@
namespace Catch {
struct AutomakeReporter final : StreamingReporterBase {
class AutomakeReporter final : public StreamingReporterBase {
public:
AutomakeReporter( ReporterConfig const& _config )
: StreamingReporterBase( _config )
{}
@ -26,7 +27,6 @@ namespace Catch {
void testCaseEnded(TestCaseStats const& _testCaseStats) override;
void skipTest(TestCaseInfo const& testInfo) override;
};
} // end namespace Catch

View File

@ -14,8 +14,8 @@
namespace Catch {
struct CompactReporter final : StreamingReporterBase {
class CompactReporter final : public StreamingReporterBase {
public:
using StreamingReporterBase::StreamingReporterBase;
~CompactReporter() override;

View File

@ -16,9 +16,10 @@ namespace Catch {
struct SummaryColumn;
class TablePrinter;
struct ConsoleReporter final : StreamingReporterBase {
class ConsoleReporter final : public StreamingReporterBase {
Detail::unique_ptr<TablePrinter> m_tablePrinter;
public:
ConsoleReporter(ReporterConfig const& config);
~ConsoleReporter() override;
static std::string getDescription();
@ -41,8 +42,8 @@ namespace Catch {
void testCaseEnded(TestCaseStats const& _testCaseStats) override;
void testRunEnded(TestRunStats const& _testRunStats) override;
void testRunStarting(TestRunInfo const& _testRunInfo) override;
private:
private:
void lazyPrint();
void lazyPrintWithoutClosingBenchmarkTable();
@ -64,7 +65,6 @@ namespace Catch {
void printSummaryDivider();
void printTestFilters();
private:
bool m_headerPrinted = false;
bool m_testRunInfoPrinted = false;
};

View File

@ -14,8 +14,8 @@
namespace Catch {
struct SonarQubeReporter final : CumulativeReporterBase {
class SonarQubeReporter final : public CumulativeReporterBase {
public:
SonarQubeReporter(ReporterConfig const& config)
: CumulativeReporterBase(config)
, xml(m_stream) {

View File

@ -12,8 +12,8 @@
namespace Catch {
struct TAPReporter final : StreamingReporterBase {
class TAPReporter final : public StreamingReporterBase {
public:
TAPReporter( ReporterConfig const& config ):
StreamingReporterBase( config ) {
m_preferences.shouldReportAllAssertions = true;

View File

@ -20,7 +20,8 @@
namespace Catch {
struct TeamCityReporter final : StreamingReporterBase {
class TeamCityReporter final : public StreamingReporterBase {
public:
TeamCityReporter( ReporterConfig const& _config )
: StreamingReporterBase( _config )
{
@ -52,7 +53,6 @@ namespace Catch {
private:
void printSectionHeader(std::ostream& os);
private:
bool m_headerPrintedForThisSection = false;
Timer m_testTimer;
};