Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Tobias Hunger
qt-creator
Commits
518bdd3b
Commit
518bdd3b
authored
Jan 11, 2010
by
Erik Verbruggen
Browse files
Fixed testcase: setting an empty ID should remove the ID.
parent
1a12895f
Changes
1
Hide whitespace changes
Inline
Side-by-side
tests/auto/qml/qmldesigner/coretests/testcore.cpp
View file @
518bdd3b
...
...
@@ -463,18 +463,6 @@ void TestCore::testModelCreateSubNode()
expectedCalls
<<
TestView
::
MethodCall
(
"nodeIdChanged"
,
QStringList
()
<<
"Blah"
<<
"Blah"
<<
""
);
QCOMPARE
(
view
->
methodCalls
(),
expectedCalls
);
try
{
childNode
.
setId
(
""
);
QFAIL
(
"Setting an invalid id does not throw an exception"
);
}
catch
(
Exception
&
exception
)
{
QCOMPARE
(
exception
.
type
(),
QString
(
"InvalidIdException"
));
}
try
{
childNode
.
setId
(
QString
());
QFAIL
(
"Setting an invalid id does not throw an exception"
);
}
catch
(
Exception
&
exception
)
{
QCOMPARE
(
exception
.
type
(),
QString
(
"InvalidIdException"
));
}
try
{
childNode
.
setId
(
"invalid id"
);
QFAIL
(
"Setting an invalid id does not throw an excxeption"
);
...
...
@@ -484,6 +472,9 @@ void TestCore::testModelCreateSubNode()
QCOMPARE
(
childNode
.
id
(),
QString
(
"Blah"
));
QCOMPARE
(
view
->
methodCalls
(),
expectedCalls
);
childNode
.
setId
(
QString
());
QVERIFY
(
childNode
.
id
().
isEmpty
());
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment