Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
ide_dataset [2020/05/03 15:42]
admin [Generate DataTable]
ide_dataset [2021/01/05 03:00] (current)
Line 1: Line 1:
 ===== IDE DataSet Editor ===== ===== IDE DataSet Editor =====
-//IDE DataSet Editor// allows you to create and edit the //dataset// for a state or transition.  The //dataset// can then be used in //TRIGGER Script// to perform //Data-Driven Testing (DDT)//+//IDE DataSet Editor// allows you to create and edit the //dataset// for a state or transition.  The //dataset// can then be used in //TRIGGER Script// to perform //Data-Driven Testing (DDT)// and [[Combinatorial Algorithms| Combinatorial Testing]].
  
 It supports combinatorial test generation algorithms including //Pairwise// algorithm. For more advanced data generation. It supports combinatorial test generation algorithms including //Pairwise// algorithm. For more advanced data generation.
  
-{{ wiki:idescreen:ide_dataset.png }}+{{wiki:idescreen:ide_dataset.png}}
  
 ---- ----
Line 10: Line 10:
 To create a dataset, click on "+" mini-button. The dataset is created with a default name, proceed to rename the dataset. To create a dataset, click on "+" mini-button. The dataset is created with a default name, proceed to rename the dataset.
  
 +New dataset created is automatically added to the dataset drop-down list for {{wiki:idescreen:ide_model_stateprop.png?linkonly | State Properties}} and {{wiki:idescreen:ide_model_transprop.png?linkonly | Transition Properties}}.
  
-=== Variables === +Dataset is assigned to state and transition by nameIf dataset is renamed after it's assigned to state or transition, you must re-assign the dataset to those states and transitions.
-Variables are added by clicking on {{http://testoptimal.com/img/add.png}}. Enter field name and the domain values to be tested with. Leave Group field blank for now, it will be explained later.+
  
-By default, fields are created to participate in the algorithm in generating test cases.  You can create a field to store the verification result which you will use to record the expected value after executing the test case using the data on that row. To create a verification field, select //V// for //Group// attribute from the dropdown list.+----
  
-Use the default (leave it blank) when creating non-verification field, which indicates that these fields are independent of each other+==== Define Variables ==== 
 +Variables are used by {{https://csrc.nist.gov/projects/automated-combinatorial-testing-for-software | Combinatorial Algorithm}} to [[#Generate DataTable]].
  
-In some cases a group of field may be related to each other and they must choose the related value from the list. For example if you have //Credit Card Type// and //Credit Card Number// fields added to the dataset and defined a list of credit card types like visa/amex/master/etc and the matching credit card number for each credit type, //Credit Card Number// must correspond to the matching //Credit Card Type//. In this case, select the same group id form //Group// attribute dropdown list for these fields+  * //Variable Name// - variables must have unique names and preferably legal java variable names 
 +  * //Data Type// - appropriate data type must be selected especially if the variables are referenced by //Derived// variables 
 +  * //Domain Values// - a list of discrete values to be used to generate (populate) [[#DataTable]] or groovy/java expression if //Derived// is checked 
 +  * //Derived// - check this box to exclude the variable from participating in the data generation.  For example the variables you will use to validate result or variables that can be derived from other variables.  If you  
 +  * //Coupling// - used to couple / tie this variable to another variable. For example CreditCardType and CreditCardNumber should be coupled together as CreditCardNumber for VISA must match CreditCardType of VISA. Variables coupled together must have the same number of //Domain// values.
  
-By sharing the same group id, fields will take the values from their lists at the same position. 
- 
-You can delete field by clicking on {{http://testoptimal.com/img/delete.png}} preceeding the field name. 
  
 ---- ----
  
 ====Generate DataTable==== ====Generate DataTable====
-Once you have the fields defined, you can generate the dataset for the fields by clicking on the //regenerate// link.+//DataTable// displays the output of the execution of [[#Combinatorial Algorithm]].
  
- +To generate //DataTable//select an algorithm from //Overall Strength// drop-down list and click start button next to it.
-//Algorithm// select from the drop down list of algorithms:+
     * pairwise     * pairwise
     * 3-wise     * 3-wise
Line 36: Line 37:
     * 5-wise     * 5-wise
     * 6-wise     * 6-wise
-    *  
-You can remove unwanted rows by clicking on {{http://testoptimal.com/img/delete.png}}. Each field in the datatable can be edited as you wish. 
  
-If you have verification field(s), they will be left blank. You can enter the appropriate values for each row. The results will be saved if //Persistence// checkbox is checked.+You may customize /edit //DataTable// under exceptional cases  
 +  * remove rows - invalid permutations (rows) 
 +  * add rows - additional required permutations 
 +  * edit values - change value, usually done for derived variables
  
-During the model execution, the dataset will be loaded and traversed. Besides the option to traverse the datatable sequentially or randomly as described above, you can also control the sequence of which row to be used first programmatically in mScript by setting the user variable //dataset name//_idx.+Be aware that any changes to //DataTable// will affect the coverageand the changes made will be lost next time //DataTable// is re-generated.
  
 ---- ----
 ==== Usage ==== ==== Usage ====
-Dataset can be assigned to a state or transition and datasets are automatically used during test generation to ensure transitions are traversed enough times to go through all rows in the dataset. +Dataset can be assigned to a state or transition. They are automatically incorporated into the test sequence generation to ensure transitions are traversed enough times to go through all rows in the dataset. 
  
-The rows in the dataset are retrieved and used as the states and transitions are traversed.  You can access the data fields on the current row with //$SYS.getData('fieldName')// in any of the state and transition //TRIGGER//+The rows in the dataset are retrieved and used as the states and transitions are traversed.  You can access the data fields on the current row in any of the state and transition //TRIGGER// 
 +   $SYS.getData('fieldName') 
 + 
 +To access the dataset outside the state/transition that dataset was assigned, use the following syntax instead: 
 +   $SYS.getDataSet('myDataSet').getData('fieldName'
 +    
 +     
  
-----