Added setWindowSize - FOR TESTING ON MAC

This commit is contained in:
NissimHadar 2018-11-02 09:57:58 -07:00
parent 58bac436ba
commit c7353e6c59
2 changed files with 11 additions and 0 deletions

View file

@ -209,3 +209,7 @@ QString TestScriptingInterface::getOperatingSystemType() {
return "UNKNOWN"; return "UNKNOWN";
#endif #endif
} }
void TestScriptingInterface::setWindowSize(int width, int height) {
qApp->getWindow()->resize(width, height);
}

View file

@ -166,9 +166,16 @@ public slots:
/**jsdoc /**jsdoc
* Returns the Operating Sytem type * Returns the Operating Sytem type
* @function Test.getOperatingSystemType * @function Test.getOperatingSystemType
* @returns {string} "WINDOWS", "MACOS" or "UNKNOWN"
*/ */
QString getOperatingSystemType(); QString getOperatingSystemType();
/**jsdoc
* Sets the size of the Window on desktop
* @function Test.getOperatingSystemType
*/
void setWindowSize(int width, int height);
private: private:
bool waitForCondition(qint64 maxWaitMs, std::function<bool()> condition); bool waitForCondition(qint64 maxWaitMs, std::function<bool()> condition);
QString _testResultsLocation; QString _testResultsLocation;