GuiTest with both libraries and the trust file in a temporary directory.
More...
|
|
void | SetUp () override |
| | Points Sonde at the temporary libraries and trust file.
|
|
void | TearDown () override |
| | Closes the windows and restores the environment.
|
|
void | useProject (const QString &checkout) |
| | Uses the project library of checkout checkout.
|
|
QString | projectDir (const QString &checkout=QStringLiteral("a")) const |
| | The project library of checkout checkout.
|
|
QString | userDir () const |
| | The user library.
|
|
QString | trustFile () const |
| | The trust file.
|
|
QJsonObject | save (const QString &templateName, const QString &qml, const QJsonObject &extra={ }) |
| | Saves qml as template templateName, with extra arguments.
|
|
QJsonObject | open (const QString &templateName, const QJsonObject &extra={ }) |
| | Opens template templateName, with extra arguments.
|
|
QJsonArray | trustEntries () const |
| | The trust file's entries.
|
|
void | SetUp () override |
| | Installs integrations and tools, builds and shows both windows.
|
|
void | TearDown () override |
| | Destroys the windows (before the server).
|
| virtual bool | withQuick () const |
| | Whether this test needs the QML window (override to skip it).
|
|
QJsonObject | call (const QString &tool, const QJsonObject &args={ }) |
| | Calls a tool and returns its result.
|
|
QString | text (const QString &tool, const QJsonObject &args={ }) |
| | Calls a tool and returns its text.
|
|
bool | fails (const QString &tool, const QJsonObject &args={ }) |
| | Calls a tool and reports whether it returned an error result.
|
|
|
static void | writeFile (const QString &path, const QString &text) |
| | Writes text to path directly, as an agent with a shell would.
|
|
static QQuickWindow * | windowOf (const QJsonObject &result) |
| | The window an ui_open result names.
|
|
|
QTemporaryDir | tmp |
| | Holds the checkouts and the configuration directory.
|
|
QmlTemplateTrust * | trust = nullptr |
| | The server's trust object.
|
|
Sonde::Server | server |
| | Server under test.
|
|
QString | name |
| | Local socket name of the server.
|
|
std::unique_ptr< LocalClient > | client |
| | Initialized client.
|
|
std::unique_ptr< QWidget > | form |
| | The widgets window ("Form Window").
|
|
QLineEdit * | edit = nullptr |
| | Line edit "edit" (has focus initially).
|
|
QPushButton * | button = nullptr |
| | Push button "button" ("&Press").
|
|
QCheckBox * | check = nullptr |
| | Check box "check".
|
|
QSlider * | slider = nullptr |
| | Horizontal slider "slider", 0-100.
|
|
QListWidget * | list = nullptr |
| | List "list" with 200 items (scrollable).
|
|
QLabel * | hiddenLabel = nullptr |
| | Hidden label "hiddenLabel".
|
|
int | buttonClicks = 0 |
| | Times button was clicked.
|
|
int | shortcutHits = 0 |
| | Times the Ctrl+K shortcut fired.
|
|
QQmlEngine | engine |
| | Engine of the QML window.
|
|
std::unique_ptr< QQuickWindow > | quick |
| | The Qt Quick window ("Quick Window").
|
|
|
static void | restore (const char *name, const QByteArray &value) |
| | Sets name back to value (unset if it was empty).
|
|
|
QByteArray | m_savedLibrary |
| | SONDE_QML_LIBRARY before the test.
|
|
QByteArray | m_savedConfig |
| | XDG_CONFIG_HOME before the test.
|
|
QByteArray | m_savedTrust |
| | SONDE_TRUST_FILE before the test.
|
GuiTest with both libraries and the trust file in a temporary directory.
The documentation for this class was generated from the following file:
- tests/gui/test_qmltemplates.cpp