script.kps 1.15 KB
Newer Older
Lulu Luong's avatar
#54  
Lulu Luong committed
1 2 3 4
script empty(){

}

Sarah Grebing's avatar
minor  
Sarah Grebing committed
5 6 7 8 9
script full(){
  impRight;
  impRight;
  impLeft;
  cases {
Sarah Grebing's avatar
Sarah Grebing committed
10
	case derivable `p`:
Sarah Grebing's avatar
minor  
Sarah Grebing committed
11 12 13 14
   }
}


Sarah Grebing's avatar
Sarah Grebing committed
15 16 17 18 19 20 21 22
script full(){
  impRight;
  impRight;
  impLeft;
  cases {
	case match `!q ==> p`:
		notLeft;
		notRight;
Sarah Grebing's avatar
Sarah Grebing committed
23 24
		closeAntec;

Sarah Grebing's avatar
Sarah Grebing committed
25 26 27 28 29 30

	case match `q==>!p`:
		notLeft;
		closeAntec;
   }
}
31

Sarah Grebing's avatar
interim  
Sarah Grebing committed
32
script autoScript(){
33 34
    __STRICT_MODE := true;
    auto;
Sarah Grebing's avatar
interim  
Sarah Grebing committed
35 36
}

Sarah Grebing's avatar
Sarah Grebing committed
37

38
script interactive(){
39
  impRight;
Sarah Grebing's avatar
Sarah Grebing committed
40
  impRight;
41
  impLeft;
Sarah Grebing's avatar
Sarah Grebing committed
42
//after execution of this script, manual interaction can be performed
43
}
44
script interactive_with_match(){
45
impRight;
LULUDBR\Lulu's avatar
LULUDBR\Lulu committed
46
impRight;
Sarah Grebing's avatar
Sarah Grebing committed
47
#save 'test0' force='yes';
48 49
impLeft;
cases{
50
    case match `==> !(?Z), ?Z`:
51
      notRight;
LULUDBR\Lulu's avatar
LULUDBR\Lulu committed
52 53 54 55

    default:
      notLeft;

56
    }
57 58

}
Sarah Grebing's avatar
Sarah Grebing committed
59 60 61 62 63 64 65 66 67

script usageOfTryInCases(){
cases{
    try: impLeft; //if this mutator is successful, do this operation otherwise use next case

    default:
        __KEY_MAX_STEPS:= 100;
        impRight;
    }
Sarah Grebing's avatar
Sarah Grebing committed
68
    auto;
69 70
}

71
script varDecl1(){
72 73 74
    var1 : INT :=  1;
    var2 : INT :=  2;
    var3 : INT :=  3;
75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96
}

script varDecl2(){
  var1 : INT :=  1;
  impRight;
  impRight;
  impLeft;
  cases {
	case match `!q ==> p`:
		notLeft;
		var2 : INT :=  2;
		notRight;



	case match `q==>!p`:
		notLeft;
		var3 : INT :=  3;
   }



Sarah Grebing's avatar
Sarah Grebing committed
97
}