This repository has been archived by the owner on Jul 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
data driven (ARRANGE language)
ETAS-Eder edited this page Aug 21, 2014
·
4 revisions
Rather than writing each concrete value into an alternative test and collect them in a test suite, one can generically specify multiple tests through data-binding.
For a generic label out label1 = "foo1_in!doSquare,x";
defined elsewhere in the (*.arr) file, one can specify
express sc0 = label1
::where (
doSquare in { true , false };
x in { 1,2,3 };
nwise (2,doSquare,x);
);
The set of concrete scenarios built from specification sc0
is how in the screenshot:
express sc1 = label1;label2;
label3::where(
doSquare in {true};
);
express sc2a =
(
label0_machine1MethodCalls;
label1::where(x in {0,3}; doSquare in {0,1});
label2::where(res in {0,9})
)::where(pairwise(x,doSquare);pairwise(res,doSquare));
express sc2b =
(
label1::where(x in {0,1,2,3,4}; doSquare in {0,1});
label2::where(x in {2,3}; doSquare in {1})
)::where(pairwise(x,doSquare));
express sc2c__ =
(
label1;
label2
)::where(x in {0,1,2,3,4}; doSquare in {0,1});
express sc3 =
(
label1::where(x in {0,1,2,3,4});
label2::where(let d1 = doSquare; d1 in {0,1});
label3::where(let d2 = doSquare)
)::where(pairwise(x,d1);pairwise(d1,d2));