Stop using Catch::toString()

This function doesn't exist in Catch2 any longer, so prepare for the
upgrade by stopping to use it and converting things to string more
explicitly.

No real changes yet.
This commit is contained in:
Vadim Zeitlin 2022-10-15 19:26:02 +02:00
parent 715b2cd48c
commit a3331c87d0
3 changed files with 6 additions and 6 deletions

View file

@ -1841,7 +1841,7 @@ TEST_CASE_METHOD(GridTestCase,
// repeat the same tests for both rows and columns as the code for
// updating them works symmetrically.
GIVEN(Catch::toString(multi))
GIVEN(multi.ToString())
{
FitGridToMulticell(m_grid, multi);
m_grid->SetMulticell(multi);
@ -1876,7 +1876,7 @@ TEST_CASE_METHOD(GridTestCase,
wxSwap(multi.rows, multi.cols);
GIVEN(Catch::toString(multi))
GIVEN(multi.ToString())
{
FitGridToMulticell(m_grid, multi);
m_grid->SetMulticell(multi);
@ -1958,7 +1958,7 @@ TEST_CASE_METHOD(GridTestCase,
Multicell multi(1, 1, 5, 3);
GIVEN(Catch::toString(multi))
GIVEN(multi.ToString())
{
FitGridToMulticell(m_grid, multi);
m_grid->SetMulticell(multi);
@ -1993,7 +1993,7 @@ TEST_CASE_METHOD(GridTestCase,
wxSwap(multi.rows, multi.cols);
GIVEN(Catch::toString(multi))
GIVEN(multi.ToString())
{
FitGridToMulticell(m_grid, multi);
m_grid->SetMulticell(multi);

View file

@ -1400,7 +1400,7 @@ FindMaxChannelDiff(const wxImage& i1, const wxImage& i2)
const wxImage imageFromFile(file); \
if ( imageFromFile.IsOk() ) \
{ \
INFO("Wrong scaled \"" << file << "\" " << Catch::toString(image)); \
INFO("Wrong scaled \"" << file << "\" " << Catch::StringMaker<wxImage>::convert(image)); \
CHECK(FindMaxChannelDiff(imageFromFile, image) <= 1); \
} \
else \

View file

@ -145,7 +145,7 @@ public:
std::string describe() const override
{
std::string desc = "doesn't have the same RGB data as " +
Catch::toString(m_image);
Catch::StringMaker<wxImage>::convert(m_image);
if ( !m_diffDesc.empty() )
desc += + ": " + m_diffDesc.ToStdString(wxConvUTF8);