make tests independent of the user's environment
There's a KTextEditor::EditorPrivate::enableUnitTestMode();
function, which is incomplete, since javascript tests look for paths in the user environment.
Except that if you go through QStandardPaths::setTestModeEnabled(true);
, you can simply replace unitTestMode()
with QStandardPaths::isTestModeEnabled();
and the tests will pass. Should we delete enableUnitTestMode()
/unitTestMode()
and simply use QStandardPaths
?