Removed Text tests (TextFlow has it's own test suite)

This commit is contained in:
Phil Nash
2017-07-20 23:09:50 +01:00
parent 93556a1fb3
commit 58d8bc6985
5 changed files with 28 additions and 1439 deletions

View File

@@ -1781,544 +1781,6 @@ PASSED:
with expansion:
1.23 <= Approx( 1.22 )
-------------------------------------------------------------------------------
Long strings can be wrapped
plain string
No wrapping
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 80 ) ).toString() == testString )
with expansion:
"one two three four"
==
"one two three four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 18 ) ).toString() == testString )
with expansion:
"one two three four"
==
"one two three four"
-------------------------------------------------------------------------------
Long strings can be wrapped
plain string
Wrapped once
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 17 ) ).toString() == "one two three\nfour" )
with expansion:
"one two three
four"
==
"one two three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 16 ) ).toString() == "one two three\nfour" )
with expansion:
"one two three
four"
==
"one two three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 14 ) ).toString() == "one two three\nfour" )
with expansion:
"one two three
four"
==
"one two three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 13 ) ).toString() == "one two three\nfour" )
with expansion:
"one two three
four"
==
"one two three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 12 ) ).toString() == "one two\nthree four" )
with expansion:
"one two
three four"
==
"one two
three four"
-------------------------------------------------------------------------------
Long strings can be wrapped
plain string
Wrapped twice
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 9 ) ).toString() == "one two\nthree\nfour" )
with expansion:
"one two
three
four"
==
"one two
three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 8 ) ).toString() == "one two\nthree\nfour" )
with expansion:
"one two
three
four"
==
"one two
three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 7 ) ).toString() == "one two\nthree\nfour" )
with expansion:
"one two
three
four"
==
"one two
three
four"
-------------------------------------------------------------------------------
Long strings can be wrapped
plain string
Wrapped three times
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 6 ) ).toString() == "one\ntwo\nthree\nfour" )
with expansion:
"one
two
three
four"
==
"one
two
three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 5 ) ).toString() == "one\ntwo\nthree\nfour" )
with expansion:
"one
two
three
four"
==
"one
two
three
four"
-------------------------------------------------------------------------------
Long strings can be wrapped
plain string
Short wrap
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "abcdef", TextAttributes().setWidth( 4 ) ).toString() == "abc-\ndef" )
with expansion:
"abc-
def"
==
"abc-
def"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "abcdefg", TextAttributes().setWidth( 4 ) ).toString() == "abc-\ndefg" )
with expansion:
"abc-
defg"
==
"abc-
defg"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "abcdefgh", TextAttributes().setWidth( 4 ) ).toString() == "abc-\ndef-\ngh" )
with expansion:
"abc-
def-
gh"
==
"abc-
def-
gh"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 4 ) ).toString() == "one\ntwo\nthr-\nee\nfour" )
with expansion:
"one
two
thr-
ee
four"
==
"one
two
thr-
ee
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 3 ) ).toString() == "one\ntwo\nth-\nree\nfo-\nur" )
with expansion:
"one
two
th-
ree
fo-
ur"
==
"one
two
th-
ree
fo-
ur"
-------------------------------------------------------------------------------
Long strings can be wrapped
plain string
As container
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
REQUIRE( text.size() == 4 )
with expansion:
4 == 4
TestMain.cpp:<line number>:
PASSED:
CHECK( text[0] == "one" )
with expansion:
"one" == "one"
TestMain.cpp:<line number>:
PASSED:
CHECK( text[1] == "two" )
with expansion:
"two" == "two"
TestMain.cpp:<line number>:
PASSED:
CHECK( text[2] == "three" )
with expansion:
"three" == "three"
TestMain.cpp:<line number>:
PASSED:
CHECK( text[3] == "four" )
with expansion:
"four" == "four"
-------------------------------------------------------------------------------
Long strings can be wrapped
plain string
Indent first line differently
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( text.toString() == " one two\n three\n four" )
with expansion:
" one two
three
four"
==
" one two
three
four"
-------------------------------------------------------------------------------
Long strings can be wrapped
With newlines
No wrapping
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 80 ) ).toString() == testString )
with expansion:
"one two
three four"
==
"one two
three four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 18 ) ).toString() == testString )
with expansion:
"one two
three four"
==
"one two
three four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 10 ) ).toString() == testString )
with expansion:
"one two
three four"
==
"one two
three four"
-------------------------------------------------------------------------------
Long strings can be wrapped
With newlines
Trailing newline
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "abcdef\n", TextAttributes().setWidth( 10 ) ).toString() == "abcdef" )
with expansion:
"abcdef" == "abcdef"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "abcdef", TextAttributes().setWidth( 6 ) ).toString() == "abcdef" )
with expansion:
"abcdef" == "abcdef"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "abcdef\n", TextAttributes().setWidth( 6 ) ).toString() == "abcdef" )
with expansion:
"abcdef" == "abcdef"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "abcdef\n", TextAttributes().setWidth( 5 ) ).toString() == "abcd-\nef" )
with expansion:
"abcd-
ef"
==
"abcd-
ef"
-------------------------------------------------------------------------------
Long strings can be wrapped
With newlines
Wrapped once
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 9 ) ).toString() == "one two\nthree\nfour" )
with expansion:
"one two
three
four"
==
"one two
three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 8 ) ).toString() == "one two\nthree\nfour" )
with expansion:
"one two
three
four"
==
"one two
three
four"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 7 ) ).toString() == "one two\nthree\nfour" )
with expansion:
"one two
three
four"
==
"one two
three
four"
-------------------------------------------------------------------------------
Long strings can be wrapped
With newlines
Wrapped twice
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 6 ) ).toString() == "one\ntwo\nthree\nfour" )
with expansion:
"one
two
three
four"
==
"one
two
three
four"
-------------------------------------------------------------------------------
Long strings can be wrapped
With wrap-before/ after characters
No wrapping
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 80 ) ).toString() == testString )
with expansion:
"one,two(three) <here>"
==
"one,two(three) <here>"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 24 ) ).toString() == testString )
with expansion:
"one,two(three) <here>"
==
"one,two(three) <here>"
-------------------------------------------------------------------------------
Long strings can be wrapped
With wrap-before/ after characters
Wrap before
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 11 ) ).toString() == "one,two\n(three)\n<here>" )
with expansion:
"one,two
(three)
<here>"
==
"one,two
(three)
<here>"
-------------------------------------------------------------------------------
Long strings can be wrapped
With wrap-before/ after characters
Wrap after
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 6 ) ).toString() == "one,\ntwo\n(thre-\ne)\n<here>" )
with expansion:
"one,
two
(thre-
e)
<here>"
==
"one,
two
(thre-
e)
<here>"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 5 ) ).toString() == "one,\ntwo\n(thr-\nee)\n<her-\ne>" )
with expansion:
"one,
two
(thr-
ee)
<her-
e>"
==
"one,
two
(thr-
ee)
<her-
e>"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( testString, TextAttributes().setWidth( 4 ) ).toString() == "one,\ntwo\n(th-\nree)\n<he-\nre>" )
with expansion:
"one,
two
(th-
ree)
<he-
re>"
==
"one,
two
(th-
ree)
<he-
re>"
-------------------------------------------------------------------------------
ManuallyRegistered
-------------------------------------------------------------------------------
@@ -5320,8 +4782,6 @@ PASSED:
with expansion:
"hot potato" == "hot potato"
hello
hello
-------------------------------------------------------------------------------
Tabs and newlines show in output
-------------------------------------------------------------------------------
@@ -5425,28 +4885,6 @@ PASSED:
with expansion:
3221225472 (0x<hex digits>) == 3221225472
-------------------------------------------------------------------------------
Text can be formatted using the Text class
-------------------------------------------------------------------------------
TestMain.cpp:<line number>
...............................................................................
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "hi there" ).toString() == "hi there" )
with expansion:
"hi there" == "hi there"
TestMain.cpp:<line number>:
PASSED:
CHECK( Text( "hi there", narrow ).toString() == "hi\nthere" )
with expansion:
"hi
there"
==
"hi
there"
-------------------------------------------------------------------------------
The NO_FAIL macro reports a failure but does not fail the test
-------------------------------------------------------------------------------
@@ -7407,7 +6845,7 @@ TestMain.cpp:<line number>
TestMain.cpp:<line number>:
PASSED:
CHECK( replaceInPlace( letters, "b", "z" ) )
CHECK( Catch::replaceInPlace( letters, "b", "z" ) )
with expansion:
true
@@ -7426,7 +6864,7 @@ TestMain.cpp:<line number>
TestMain.cpp:<line number>:
PASSED:
CHECK( replaceInPlace( letters, "c", "z" ) )
CHECK( Catch::replaceInPlace( letters, "c", "z" ) )
with expansion:
true
@@ -7445,7 +6883,7 @@ TestMain.cpp:<line number>
TestMain.cpp:<line number>:
PASSED:
CHECK( replaceInPlace( letters, "a", "z" ) )
CHECK( Catch::replaceInPlace( letters, "a", "z" ) )
with expansion:
true
@@ -7464,7 +6902,7 @@ TestMain.cpp:<line number>
TestMain.cpp:<line number>:
PASSED:
CHECK( replaceInPlace( letters, "g", "z" ) )
CHECK( Catch::replaceInPlace( letters, "g", "z" ) )
with expansion:
true
@@ -7483,7 +6921,7 @@ TestMain.cpp:<line number>
TestMain.cpp:<line number>:
PASSED:
CHECK( replaceInPlace( letters, letters, "replaced" ) )
CHECK( Catch::replaceInPlace( letters, letters, "replaced" ) )
with expansion:
true
@@ -7502,7 +6940,7 @@ TestMain.cpp:<line number>
TestMain.cpp:<line number>:
PASSED:
CHECK_FALSE( replaceInPlace( letters, "x", "z" ) )
CHECK_FALSE( Catch::replaceInPlace( letters, "x", "z" ) )
with expansion:
!false
@@ -7521,7 +6959,7 @@ TestMain.cpp:<line number>
TestMain.cpp:<line number>:
PASSED:
CHECK( replaceInPlace( s, "'", "|'" ) )
CHECK( Catch::replaceInPlace( s, "'", "|'" ) )
with expansion:
true
@@ -8152,6 +7590,6 @@ MiscTests.cpp:<line number>:
PASSED:
===============================================================================
test cases: 185 | 133 passed | 48 failed | 4 failed as expected
assertions: 940 | 821 passed | 98 failed | 21 failed as expected
test cases: 182 | 130 passed | 48 failed | 4 failed as expected
assertions: 898 | 779 passed | 98 failed | 21 failed as expected