summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-09-29 11:24:38 (GMT)
committerBrad King <brad.king@kitware.com>2017-09-29 11:24:38 (GMT)
commit3d9c8c1501ef50d9091344ed5f32734a52bc38b8 (patch)
tree4af53d27af40420131190d50b3104de465e80415 /test
parent1c8efb95b7d48e5603fde7cb3e1ffbec10459ed1 (diff)
downloadCastXML-3d9c8c1501ef50d9091344ed5f32734a52bc38b8.zip
CastXML-3d9c8c1501ef50d9091344ed5f32734a52bc38b8.tar.gz
CastXML-3d9c8c1501ef50d9091344ed5f32734a52bc38b8.tar.bz2
test: Fix test output conversion for `[` and `]`
When using `TEST_UPDATE` to convert the actual test output to the expected test output we must convert `[` and `]` to `\[` and `\]` to ensure it matches the actual content.
Diffstat (limited to 'test')
-rw-r--r--test/run.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/run.cmake b/test/run.cmake
index 635c27b..15cdfed 100644
--- a/test/run.cmake
+++ b/test/run.cmake
@@ -90,7 +90,7 @@ if(msg)
if("$ENV{TEST_UPDATE}" AND expect_xml_file AND EXISTS "${xml}")
set(update_xml "${actual_xml}")
string(REGEX REPLACE "^<\\?xml version=\"1.0\"\\?>" "^<\\\\?xml version=\"1.0\"\\\\?>" update_xml "${update_xml}")
- string(REGEX REPLACE "([(*)])" "\\\\\\1" update_xml "${update_xml}")
+ string(REGEX REPLACE "([][(*)])" "\\\\\\1" update_xml "${update_xml}")
string(REGEX REPLACE "<CastXML[^>]*>" "<CastXML[^>]*>" update_xml "${update_xml}")
string(REGEX REPLACE "<GCC_XML[^>]*>" "<GCC_XML[^>]*>" update_xml "${update_xml}")
string(REGEX REPLACE "mangled=\"[^\"]*\"" "mangled=\"[^\"]+\"" update_xml "${update_xml}")