PICT 3.3 User’s Guide
Jacek Czerwonka, Test Lead, Microsoft Corporation

Overview
Using PICT to Combine Test Case Parameters
Running PICT
Model Files
Model Sections
Simple Model
Pairwise and Higher-Order Generation
Sub-Models
Model Options
Constraints
Conditional Constraints
Unconditional Constraints (Invariants)
Parameter Types
Aliasing
Negative Testing
Weighting
Seeding
Output Randomization
Minimizing the Number of Test Cases
Case Sensitivity
Output Format
Warning Messages
All or no values satisfy relation…
Restrictive constraints. Output will not contain following values…
Sample Models
Complete Model File for the Volume Partitioning Example
Model to Test Hardware Configurations
Constraints Syntax Examples

Overview
The Pairwise Independent Combinatorial Testing tool (PICT) can help you efficiently design test cases and test configurations for software systems. With PICT, you can generate tests that are more effective than manually generated tests and create them in a fraction of the time required by hands-on test case design. PICT generates a compact set of parameter value choices that represent the test cases you should use to get comprehensive combinatorial coverage of your parameters.

Using PICT to Combine Test Case Parameters
PICT runs as a command line tool. You prepare a model file detailing the parameters of the interface (or set of configurations, or data) you want to test. PICT generates a compact set of parameter value choices that represent the test cases you should use to get comprehensive combinatorial coverage of your parameters.

For instance, if you wish to create a test suite for partition and volume creation, the domain can be described by the following parameters: Type, Size, File system, Format method, Cluster size, and Compression. Each parameter has a limited number of possible values, each of which is determined by its nature (for example, Compression can only be On or Off) or as an equivalence partition (such as Size).

Type: Primary, Logical, Single, Span, Stripe, Mirror, RAID-5
Size: 10, 100, 500, 1000, 5000, 10000, 40000
Format method: quick, slow
File system: FAT, FAT32, NTFS
Cluster size: 512, 1024, 2048, 4096, 8192, 16384, 32768, 65536
Compression: on, off

There are over 4,700 possible combinations of these values. It would be very difficult to test all of them in a reasonable amount of time. Research shows that testing all pairs of possible values provides very good coverage and the number of test cases will remain manageable. For example, {Primary, FAT} is one pair and {10, slow} is another; a single test case can cover many pairs.

For the set of parameters shown above, PICT will produce 60 test cases. The last section of this guide contains a complete model for this volume/partition example.
Running PICT
PICT is a command-line tool that accepts a plain-text model file as an input and outputs a set of test cases.

Usage: pict model [options]

Options:
/o:N - Order of combinations (default: 2)
/d:C - Separator for values (default: ,)
/a:C - Separator for aliases (default: |)
/n:C - Negative value prefix (default: ~)
/e:file - File with seeding rows
/r[:N] - Randomize generation, N - seed
/c - Case-sensitive model evaluation
/s - Show model statistics
The PICT installer adds PICT to the path, so you can run it from any folder on your system. To see the PICT output for the example in the previous section, create the model file with any plain text editor, such as Windows® Notepad®, and run PICT with this command:
C:\YourFolder> pict ModelFile.txt
To create a tab-delimited output file, use command line output redirection.
C:\YourFolder> pict ModelFile.txt > OutputFile.txt
You can use Microsoft® Excel® to sort or filter PICT’s output. You either import the output file into Excel, or use an .xls extension when you create the file and open it directly in Excel.
C:\YourFolder> pict ModelFile.txt > OutputFile.xls
C:\YourFolder> OutputFile.xls

Model Files
Model Sections
A model consists of at least one, and at most, three sections:

parameter definitions

[sub-model definitions]

[constraint definitions]

Model sections should always be specified in the order shown above and cannot overlap. The parameters definition section comes first, followed by the optional sub-model and constraints sections, if you use them. Sections do not require any special separators between them. Empty lines can appear anywhere. You can include comments by prefixing lines with the “#”character.

Simple Model
To produce a very basic model file, list parameter names–each on a separate line–with their possible values delimited by commas:

: , , , ...

Example:


/#
/# This is a sample model for testing volume create/delete functions
/#

Type: Primary, Logical, Single, Span, Stripe, Mirror, RAID-5
Size: 10, 100, 500, 1000, 5000, 10000, 40000
Format method: quick, slow
File system: FAT, FAT32, NTFS
Cluster size: 512, 1024, 2048, 4096, 8192, 16384, 32768, 65536
Compression: on, off


A comma is the default separator but you can specify a different one using /d: option.

Pairwise and Higher-Order Generation
By default, PICT generates a pairwise, or order two, suite of test cases–all pairs covered. You can set the order to a value larger than two using the option /o:. For example, if you specify /o:3, the resultant test cases will cover all triplets of values, producing a larger number of tests than the pairwise option, but potentially giving the test suite more coverage. The maximum order for a simple model is equal to the number of parameters, which will result in an exhaustive, all possible combinations, test suite. Following the same principle, specifying /o:1 will produce a test suite that covers all values only once (combinations of 1).

PICT用户手册 [转]的更多相关文章

  1. Rafy 框架-发布网页版用户手册

    前段时间把 Rafy 的用户手册由 CHM 格式转换为了网页格式,而且发布到了 github.io 上,即方便文档的实时更新,也方便大家查看. Rafy 用户手册网页版地址: http://zgynh ...

  2. sqlmap用户手册 | WooYun知识库

    sqlmap用户手册 说明:本文为转载,对原文中一些明显的拼写错误进行修正,并标注对自己有用的信息. 原文:http://drops.wooyun.org/tips/143  ============ ...

  3. pict(Pairwise Independent Combinatorial Testing)工具使用

    PICT工具就是在微软公司内部使用的一款成对组合的命令行生成工具,现在已经对外提供,可以在互联网上下载到. 要把输入类型和其对应的参数输入到一个CSV格式(CSV: 以逗号分割的纯文本文件,不带有任何 ...

  4. PICT安装与使用

    一.PICT简介 PICT工具是在微软公司推出的一款成对组合的命令行生成工具,下载地址http://download.microsoft.com/download/f/5/5/f55484df-849 ...

  5. 用例设计工具PICT — 输入组合覆盖

    1 成对测试简介 成对测试(Pairwise Testing)又称结对测试.两两测试,是一种正交分析的测试技术.成对组合覆盖这一概念是Mandl于1985年在测试Aad编译程序时提出来的.是当不可能遍 ...

  6. Windows Azure Web Site (1) 用户手册

    <Windows Azure Platform 系列文章目录> 下载地址: Web Apps用户手册

  7. Windows Azure Cloud Service (1) 用户手册

    <Windows Azure Platform 系列文章目录> 下载地址 Cloud Service用户手册

  8. Windows Azure Virtual Machine (1) IaaS用户手册

    <Windows Azure Platform 系列文章目录> Azure IaaS用户手册  - Azure IaaS相关技术- Azure虚拟机成本分析- 创建Azure虚拟机- 使用 ...

  9. Azure SQL Database (1) 用户手册

    <Windows Azure Platform 系列文章目录> 最新更新2016年6月17日 下载地址:Azure SQL Database用户手册

随机推荐

  1. LibreOJ #6013. 「网络流 24 题」负载平衡 最小费用最大流 供应平衡问题

    #6013. 「网络流 24 题」负载平衡 内存限制:256 MiB时间限制:1000 ms标准输入输出 题目类型:传统评测方式:文本比较 上传者: 匿名 提交提交记录统计讨论测试数据   题目描述 ...

  2. Python压缩文件夹 tar.gz .zip

    打包压缩生成 XXX.tar.gz 文件 import os import tarfile if os.path.exists(outputFileName): with tarfile.open(o ...

  3. JavaScript学习笔记:基础知识点总结

    基础概念 JavaScript(以下简称Js)中数据类型:Number 字符串 布尔值 数组 对象(Js的对象是一组由键值对组成的无序集合) Js中基础概念:变量(概念和Java中变量概念类似 指示某 ...

  4. Spark学习笔记-GraphX-1

    Spark学习笔记-GraphX-1 标签: SparkGraphGraphX图计算 2014-09-29 13:04 2339人阅读 评论(0) 收藏 举报  分类: Spark(8)  版权声明: ...

  5. 【C#】解析C#中JSON.NET的使用

    目录结构: contents structure [-] JSON.NET简介 Serializing and Deserializing JSON Json Convert Json Seriali ...

  6. 组合数问题(NOIP2016)

    题目链接:组合数问题 这道题可以算当年第二简单的. 这里要用到两个技巧: 用杨辉三角递推计算组合数 运用前缀和 有了这两点,这道题就出来了. 我们先运用杨辉三角推出题目范围内所能用到的所有组合数,然后 ...

  7. 统计方形(NOIP1997)

    给链接:统计方形 这题是棋盘问题的数据加强版. 其实由于洛谷的数据比较水,所以你把我在棋盘问题题解中写的代码提交,也能AC. 但让给我们来看一个更优的解法. 先给代码: #include<bit ...

  8. django之http

    一 http协议介绍 http协议(Hyper Text Transfer Protocol):超文本传输协议,是基于应用层的面向对象协议,靠tcp协议和IP来传输数据,请求和响应是http协议的基本 ...

  9. win10 VMware ubuntu12.04 虚拟机不能上网【已解决】

    参考  :链接. 本机环境:Ubuntu 12.04 无线上网(连接手机热点). 主机:Win 10. 步骤1:VMware安装运行后,默认会有3个虚拟网络,VMnet0,VMnet1,VMnet8. ...

  10. centos firewalld 基本操作【转】

    1.firewalld的基本使用启动: systemctl start firewalld关闭: systemctl stop firewalld查看状态: systemctl status fire ...