Commit feb6b25b authored by Ronan Abhamon's avatar Ronan Abhamon

fix(utils.spec.qml): add missing `.` and test if `dialog` is not returned in `test_openDialog`

parent 32dc8354
...@@ -26,6 +26,10 @@ TestCase { ...@@ -26,6 +26,10 @@ TestCase {
fail(e) fail(e)
} }
if (dialog == null) {
fail('`dialog` is not returned')
}
dialog.close() dialog.close()
} }
...@@ -70,13 +74,13 @@ TestCase { ...@@ -70,13 +74,13 @@ TestCase {
}) })
if (!failed) { if (!failed) {
fail('`setTimeout` callback was called before `wait`') fail('`setTimeout` callback was called before `wait`.')
} }
wait(200) wait(200)
if (failed) { if (failed) {
fail('`setTimeout` failed because callback it was not called in due course') fail('`setTimeout` failed because callback it was not called in due course.')
} }
} }
...@@ -101,14 +105,14 @@ TestCase { ...@@ -101,14 +105,14 @@ TestCase {
}) })
if (failed) { if (failed) {
fail('`setTimeout` callback was called') fail('`setTimeout` callback was called before `wait`.')
} }
Utils.clearTimeout(timeout) Utils.clearTimeout(timeout)
wait(100) wait(100)
if (failed) { if (failed) {
fail('`setTimeout` callback was called') fail('`setTimeout` callback was called after `wait`.')
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment