Indicate that QuickTestLib is running

QTestLib already sets this environment variable to indicate that
the code is running on a test environment. Do the same for QuickTest
too.

Change-Id: I597237fcd16dc568b750bdef325881e808c407eb
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
This commit is contained in:
Laszlo Agocs 2015-09-09 13:54:03 +02:00
parent 36d95bd2ab
commit 3713120cc8
1 changed files with 2 additions and 0 deletions

View File

@ -315,6 +315,8 @@ int quick_test_main(int argc, char **argv, const char *name, const char *sourceD
return 1;
}
qputenv("QT_QTESTLIB_RUNNING", "1");
// Register the test object
qmlRegisterSingletonType<QTestRootObject>("Qt.test.qtestroot", 1, 0, "QTestRootObject", testRootObject);
// Scan through all of the "tst_*.qml" files and run each of them