ssu
Classes | Public Types | Static Public Member Functions | List of all members
UpgradeTestHelper Class Reference

Utilities to generate upgrade-test data. More...

Classes

struct  TestCase
 

Public Types

enum  { HistoryLength = 5, CurrentVersion = 3 }
 

Static Public Member Functions

static QList< TestCasereadRecipe (QIODevice *recipe)
 
static void fillSettings (QSettings *settings, const QList< TestCase > &testCases)
 
static void fillDefaultSettings (QSettings *defaultSettings, const QList< TestCase > &testCases)
 
static bool generateSnapshotRecipe (QTextStream *out)
 
static QStringList groups ()
 

Detailed Description

Utilities to generate upgrade-test data.

It is driven by recipe in following format.

Every line consists of three values delimited by colon:

* <history>:<current>:<expected>
* 

Action (S)et results in assigning "v<revision>-default" to the key, e.g., "v5-default" when 'S' appears as 5th letter in the history word.

The key is built as "<history>__<current>".

Example:

* SKNRN:v1-default:@NOTSET@
* SSNSN:v2-default:v4-default
* 

Generated settings:

* [Global]
* configVersion = 2
* SKNRN__v1-default = v1-default
* SSNSN__v2-default = v2-default
*
* [groupA]
* SKNRN__v1-default = v1-default
* SSNSN__v2-default = v2-default
* 

Generated default settings:

* [Global]
* configVersion = 5
*
* [1]
* SKNRN__v1-default = v1-default
* groupA\SKNRN__v1-default = v1-default
* SSNSN__v2-default = v1-default
* groupA\SSNSN__v2-default = v1-default
*
* [2]
* SKNRN__v1-default = v1-default
* groupA\SKNRN__v1-default = v1-default
* SSNSN__v2-default = v2-default
* groupA\SSNSN__v2-default = v2-default
*
* [3]
*
* [4]
* cmd-remove = SKNRN__v1-default, groupA/SKNRN__v1-default
* SSNSN__v2-default = v4-default
* groupA\SSNSN__v2-default = v4-default
*
* [5]
* 

Definition at line 18 of file upgradetesthelper.h.


The documentation for this class was generated from the following files: