Added test cases. ref #814.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2018-06-18 15:04:47 +03:00
parent a59e031b81
commit da1d94a749

View File

@ -128,6 +128,8 @@ void TST_NameRegExp::TestNameRegExp_data()
QTest::newRow("First character can't be \"<\"") << "<a" << false;
QTest::newRow("First character can't be \">\"") << ">a" << false;
QTest::newRow("First character can be \"\\\"") << "\\a" << true;
QTest::newRow("Any next character can't be \"+\"") << "a+" << false;
QTest::newRow("Any next character can't be \"*\"") << "a*" << false;
QTest::newRow("Any next character can't be \"/\"") << "a/" << false;
@ -146,6 +148,8 @@ void TST_NameRegExp::TestNameRegExp_data()
QTest::newRow("Any next character can't be \"<\"") << "a<" << false;
QTest::newRow("Any next character can't be \">\"") << "a>" << false;
QTest::newRow("Any next character can be \"\\\"") << "a\\" << true;
QTest::newRow("Good name \"p12\"") << "p12" << true;
QTest::newRow("Good name \"height\"") << "height" << true;
QTest::newRow("Good name \"A_1\"") << "A_1" << true;