Testcover.com
Tutorial - Constraints Example

Home
Existing User Login
Brochure
Sign up for Risk-Free Trial
About Testcover.com
Frequently Asked Questions
Tutorial
->Definitions of Terms
->Need for the Service
->Submitting Requests
->Reading Results
->Configuration Example
->Constraints Example
->Calendar Example
->RDF/XML Example
Performance
Background
Partners
Subscription Prices
Promotion Activations
Student Subscriptions
Privacy Policy
Terms & Conditions
Contact Information


The Constraints Example is summarized below. The test system has five test factors with values as follows.
Test FactorNumber of ValuesTest Factor Values
1. Operating system4WXP OSX10 LNX9 WME
2. Display resolution3low medium high
3. Connection4dial-up dsl cable lan
4. Browser4IE6 NS7 MZL1.5 IE5
5. Application3App1 App2 App3
The test cases need to be constrained to avoid three combinations which are not allowed:
• OSX10 with IE6
• LNX9 with IE6
• LNX9 with IE5
This is accomplished using multiple blocks which are defined so that the union of their test cases spans all the allowed test cases. There are several ways to do this.

The first way to define the blocks is by operating system. One block defines the allowed test cases for WXP and WME. Another defines the allowed test cases for OSX10, and a third defines them for LNX9. The supported browsers are included in their respective blocks. (See the request below.)

The second way to define the blocks is by browser. One block defines the allowed test cases for NS7 and MZL1.5. Another defines the allowed test cases for IE5, and a third defines them for IE6. The supported operating systems are included in their respective blocks. The key here is that any test case defined by a block is allowed. When the blocks are taken together, they define all the allowed test cases and none of the disallowed ones.

It is possible to specify blocks that overlap in various ways also. All of these block definitions are equivalent when they exclude the three unsupported combinations. They lead to test cases covering all the allowed combinations. However different block definitions lead to minor variations in the resulting test cases.

The following request illustrates the constraints example with the blocks defined by operating system. (The text following the plus (+) on the first line of the block is an optional comment.)
Constraints Example - Disjoint Operating System Blocks
Operating System
Display resolution
Connection
Browser
Application
#
+ (WXP WME) with (IE6 NS7 MZL1.5 IE5)
WXP WME
low medium high
dial-up dsl cable lan
IE6 NS7 MZL1.5 IE5
App1 App2 App3
+ OSX10 with (NS7 MZL1.5 IE5)
OSX10
low medium high
dial-up dsl cable lan
NS7 MZL1.5 IE5
App1 App2 App3
+ LNX9 with (NS7 MZL1.5)
LNX9
low medium high
dial-up dsl cable lan
NS7 MZL1.5
App1 App2 App3

The results table is shown below. It has columns for a Test Case ID, for each test factor and for a Combo Countdown. The top row of the table labels these columns. The next row shows the number of values for each factor and the total number of factor value pairs in the Combo Countdown column.
Test
Case ID
Operating System Display resolution Connection Browser Application Combo
Countdown
4 Values3 Values4 Values4 Values3 Values129
1WMElowdslIE5App1119
2WMEhighlanIE6App2109
3WMEmediumcableMZL1.5App399
4WXPmediumlanNS7App189
5OSX10highdial-upIE5App379
6WXPhighdslMZL1.5App270
7LNX9highcableNS7App261
8WXPlowdial-upIE6App153
9OSX10lowlanMZL1.5App345
10LNX9mediumdial-upMZL1.5App238
11OSX10lowcableIE5App232
12LNX9mediumdslNS7App326
13WXPmediumcableIE6App122
14OSX10lowdial-upNS7App118
15WMEhighdial-upMZL1.5App115
16OSX10mediumdslIE5App112
17LNX9lowlanNS7App19
18WMEmediumdslIE6App37
19WXPlowdial-upIE5App35
20WMElowcableNS7App24
21WMEmediumlanIE5App33

In this example there are

4 • 3+ 4 • 4+ 4 • 4+ 4 • 3
+ 3 • 4+ 3 • 4+ 3 • 3
+ 4 • 4+ 4 • 3
+ 4 • 3= 129
uncovered pairs of values before any test cases are run. The row labeled 1 gives the values of the test factors for the first test case. It also shows that after the first test case is run, 119 pairs of values remain uncovered. (10 pairs of values are covered by each of the first five test cases.) Successive rows give the suggested test cases with their corresponding numbers of uncovered factor value pairs in the Combo Countdown column. After test case number 21, all but three pairs of values are covered. These are the three unsupported combinations which cannot be tested.

In this example there must be at least 4 • 4 = 16 test cases to include the pairs of values for the two factors with the most values (4). If there were no constraints, the generator would produce exactly 16 test cases here. However because there are constraints in the test system, a few additional test cases are required.

<Configuration Example Calendar Example>
Copyright © 2003-2008 Testcover.com, LLC. All rights reserved.