Progmasoft Git

catch3

Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.

Clonegit clone https://git.progmasoft.com/catch3

Filter out version number from approval tests

Commit
a35ee200da177e406058af3f6df81de72993d953
Author
Phil Nash ·
Parents
16c21ee2656d

Files · Download .tar.gz

Changes

 projects/SelfTest/Baselines/console.std.approved.txt  | 2 +-
 projects/SelfTest/Baselines/console.sw.approved.txt   | 2 +-
 projects/SelfTest/Baselines/console.swa4.approved.txt | 2 +-
 scripts/approvalTests.py                              | 4 ++++
 4 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/projects/SelfTest/Baselines/console.std.approved.txt b/projects/SelfTest/Baselines/console.std.approved.txt
index e0c6f549..83d78122 100644
--- a/projects/SelfTest/Baselines/console.std.approved.txt
+++ b/projects/SelfTest/Baselines/console.std.approved.txt
@@ -1,6 +1,6 @@
 
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-CatchSelfTest is a Catch v1.0 b10 host application.
+CatchSelfTest is a <version> host application.
 Run with -? for options
 
 -------------------------------------------------------------------------------
diff --git a/projects/SelfTest/Baselines/console.sw.approved.txt b/projects/SelfTest/Baselines/console.sw.approved.txt
index 7540bd0a..6d518bf5 100644
--- a/projects/SelfTest/Baselines/console.sw.approved.txt
+++ b/projects/SelfTest/Baselines/console.sw.approved.txt
@@ -1,6 +1,6 @@
 
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-CatchSelfTest is a Catch v1.0 b10 host application.
+CatchSelfTest is a <version> host application.
 Run with -? for options
 
 -------------------------------------------------------------------------------
diff --git a/projects/SelfTest/Baselines/console.swa4.approved.txt b/projects/SelfTest/Baselines/console.swa4.approved.txt
index eedab652..aa5e2493 100644
--- a/projects/SelfTest/Baselines/console.swa4.approved.txt
+++ b/projects/SelfTest/Baselines/console.swa4.approved.txt
@@ -1,6 +1,6 @@
 
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-CatchSelfTest is a Catch v1.0 b10 host application.
+CatchSelfTest is a <version> host application.
 Run with -? for options
 
 -------------------------------------------------------------------------------
diff --git a/scripts/approvalTests.py b/scripts/approvalTests.py
index 4d072378..f39553dd 100644
--- a/scripts/approvalTests.py
+++ b/scripts/approvalTests.py
@@ -12,6 +12,7 @@ filelineParser = re.compile( r'(.*\..pp:)([0-9]*)(.*)' )
 lineNumberParser = re.compile( r'(.*)line="[0-9]*"(.*)' )
 hexParser = re.compile( r'(.*)\b(0[xX][0-9a-fA-F]+)\b(.*)' )
 durationsParser = re.compile( r'(.*)time="[0-9]*\.[0-9]*"(.*)' )
+versionParser = re.compile( r'(.*?)Catch v[0-9]*.[0-9]* b[0-9]*(.*)' )
 
 if len(sys.argv) == 2:
 	cmdPath = sys.argv[1]
@@ -31,6 +32,9 @@ def filterLine( line ):
 		m = lineNumberParser.match( line )
 		if m:
 			line = m.group(1) + m.group(2)
+	m = versionParser.match( line )
+	if m:
+		line = m.group(1) + "<version>" + m.group(2)
 
 	while True:
 		m = hexParser.match( line )