Meego Wiki
Views

Quality/QA-tools/QmlUITestlib

From MeeGo wiki
< Quality | QA-tools
Revision as of 03:45, 30 May 2011 by Shaofeng (Talk | contribs)
Jump to: navigation, search

Contents

MeeGo QML UI Testlib

Overview

MeeGo QML UI Testlib is an open tool for testing against MeeGo QML GUI application automatically. The test framework is based on "TDriver", and provide a set of pre-defined cucumber steps for designer to prepare test cases with natural language. and also BAT and L10N test cases of MeeGo QML UI applications are also involved in Testlib.

Architecture

Testlib architecture.png

BAT and L10N Test cases and a pre-defined library, in which many Cucumber steps are involved for covering all actions on MeeGo QML UI applications, are included in this Testlib.

Installation

This tool is based on cucumber and TDriver. make sure if TDriver and cucumber already work well on your machine.

Verifying if TDriver works well:

$> tdriver_visualizer &

Check if visualizer could connect to device via sut_qt.

Verifying if Cucumber works well

$> cucumber --help

For TDriver installation, please refer to Quality/QA-tools/TDriver#Installation. For cucumber, please refer to Cucumber Home site

For downloading this tools, just run "git clone ssh://..."(The git project is still under preparing)

Dependency

Because the patch "QML_ID" isn't accepted by neither Qt upstream, nor MeeGo QT maintainer. so we need to update the qt-related packages by ourselves. for the latest images, an OBS repository is available for this patch.

Usage

Run existing test cases

some BAT test cases are also provided for MeeGo applications. For running them, follow below steps:

$> cd <Testlib_HOME>

$> cucumber

Prepare your own scenarios (test cases)

Besides running the existed test cases, you can also define your own scenario (test cases) using the predefined cucumber steps.

For instance, you can define a new test cases for verifying if MeeGo browser can access a new web site (for instance, Amazon).

 Scenario: Check if browser works for Amazon
   Given I launch meego browser
   And I sleep "5" second
   And I input "www.amazon.com" into "urlTextInput"
   And I sleep "5" second
   Then In meego browser, I should see "Amazon"
   And In meego browser, I should see "Sign in"
Personal tools