Changeset 1205
- Timestamp:
- 05/01/13 14:33:31 (12 years ago)
- Location:
- trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors
- Files:
-
- 23 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/contains/ContainsAndEndsWithEventTest.java
r1171 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 46 46 "}"; 47 47 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 48 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).contains(TEXT_INPUT).endsWith(TEXT_INPUT).build();48 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).contains(TEXT_INPUT).endsWith(TEXT_INPUT).build(); 49 49 // When 50 50 boolean patternContained = pattern.containedIn(taskTree); … … 66 66 "}"; 67 67 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 68 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SELECTION).contains(TEXT_INPUT).endsWith(MOUSE_CLICK).build();68 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SELECTION).contains(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 69 69 // When 70 70 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/contains/ContainsEventTest.java
r1171 r1205 23 23 24 24 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 25 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;25 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 27 27 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 28 28 … … 45 45 "}"; 46 46 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 47 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).contains(TEXT_INPUT).build();47 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).contains(TEXT_INPUT).build(); 48 48 // When 49 49 boolean patternContained = pattern.containedIn(taskTree); … … 64 64 "}"; 65 65 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 66 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SELECTION).contains(TEXT_INPUT).build();66 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SELECTION).contains(TEXT_INPUT).build(); 67 67 // When 68 68 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/contains/ContainsPatternTest.java
r1171 r1205 23 23 24 24 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 25 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;25 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 27 27 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 28 28 … … 50 50 "}"; 51 51 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 52 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();53 UsagePattern containsPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(TEXT_INPUT).build();54 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).contains(containsPattern).build();52 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 53 InteractionPattern containsPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(TEXT_INPUT).build(); 54 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).contains(containsPattern).build(); 55 55 // When 56 56 boolean patternContained = pattern.containedIn(taskTree); … … 79 79 "}"; 80 80 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 81 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SELECTION).contains(TEXT_INPUT).build();81 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SELECTION).contains(TEXT_INPUT).build(); 82 82 // When 83 83 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/endswith/EndsWithEventTest.java
r1171 r1205 22 22 23 23 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 24 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;25 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;24 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 25 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 26 26 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 27 27 … … 52 52 "}"; 53 53 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 54 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).endsWith(TEXT_INPUT).build();54 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).endsWith(TEXT_INPUT).build(); 55 55 // When 56 56 boolean patternContained = pattern.containedIn(taskTree); … … 83 83 "}"; 84 84 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 85 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).endsWith(TEXT_INPUT).build();85 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).endsWith(TEXT_INPUT).build(); 86 86 // When 87 87 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/endswith/EndsWithPatternTest.java
r1171 r1205 25 25 26 26 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;28 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 28 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 29 29 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 30 30 … … 39 39 40 40 @Test 41 public void starts_with_pattern_positive() {41 public void ends_with_pattern_positive() { 42 42 // Given 43 43 String spec = "UserSession {" + … … 48 48 " Sequence seq2 {" + 49 49 " TextInput target4 {}" + 50 " MouseClick target 2{}" +50 " MouseClick target5 {}" + 51 51 " }" + 52 52 " }" + … … 54 54 " Sequence seq3 {" + 55 55 " TextInput target4 {}" + 56 " EventTask target 2{}" +56 " EventTask target3 {}" + 57 57 " }" + 58 58 " }" + … … 60 60 "}"; 61 61 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 62 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();63 UsagePattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();64 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).endsWith(endsWithPattern).build();62 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 63 InteractionPattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 64 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).endsWith(endsWithPattern).build(); 65 65 // When 66 66 boolean patternContained = pattern.containedIn(taskTree); … … 70 70 71 71 @Test 72 public void starts_with_pattern_negative() {72 public void ends_with_pattern_negative() { 73 73 // Given 74 74 String spec = "UserSession {" + 75 " Selection sel1 {" + 76 " Sequence seq1 {" + 77 " EventTask target1 {}" + 78 " EventTask target2 {}" + 79 " }" + 80 " }" + 81 " Selection sel1 {" + 82 " Iteration it1 {" + 83 " Sequence seq2 {" + 84 " MouseClick target5 {}" + 85 " EventTask target4 {}" + 75 " Sequence seg0 {" + 76 " Selection sel1 {" + 77 " Sequence seq1 {" + 78 " EventTask target1 {}" + 86 79 " EventTask target2 {}" + 87 80 " }" + 88 81 " }" + 89 " }" + 90 " Selection sel1 {" + 91 " Sequence seq3 {" + 92 " EventTask target5 {}" + 93 " EventTask target6 {}" + 82 " Selection sel1 {" + 83 " Iteration it1 {" + 84 " Sequence seq2 {" + 85 " MouseClick target5 {}" + 86 " EventTask target4 {}" + 87 " EventTask target2 {}" + 88 " }" + 89 " }" + 90 " }" + 91 " Selection sel1 {" + 92 " Sequence seq3 {" + 93 " EventTask target5 {}" + 94 " EventTask target6 {}" + 95 " }" + 94 96 " }" + 95 97 " }" + 96 98 "}"; 97 99 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 98 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();99 UsagePattern endsWithPattern = patternBuilder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).contains(TEXT_INPUT).build();100 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).endsWith(endsWithPattern).build();100 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 101 InteractionPattern endsWithPattern = patternBuilder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).contains(TEXT_INPUT).build(); 102 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).endsWith(endsWithPattern).build(); 101 103 // When 102 104 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsAndEndsWithEventAndContainsEventTest.java
r1170 r1205 23 23 24 24 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 25 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;25 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 27 27 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 28 28 … … 52 52 "}"; 53 53 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 54 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build();54 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 55 55 // When 56 56 boolean patternContained = pattern.containedIn(taskTree); … … 83 83 "}"; 84 84 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 85 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build();85 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 86 86 // When 87 87 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsAndEndsWithEventTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 52 52 "}"; 53 53 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 54 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();54 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 55 55 // When 56 56 boolean patternContained = pattern.containedIn(taskTree); … … 76 76 "}"; 77 77 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 78 UsagePattern pattern = new UsagePatternBuilder().concernedNode(ITERATION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();78 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(ITERATION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 79 79 // When 80 80 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsAndEndsWithPatternAndContainsPatternTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 55 55 "}"; 56 56 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 57 UsagePatternBuilder builder = new UsagePatternBuilder();58 UsagePattern startsWithPattern = builder.concernedNode(ITERATION).contains(MOUSE_CLICK).build();59 UsagePattern containedPattern = builder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build();60 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).contains(TEXT_INPUT).build();61 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containedPattern).endsWith(endsWithPattern).build();57 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 58 InteractionPattern startsWithPattern = builder.concernedNode(ITERATION).contains(MOUSE_CLICK).build(); 59 InteractionPattern containedPattern = builder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 60 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).contains(TEXT_INPUT).build(); 61 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containedPattern).endsWith(endsWithPattern).build(); 62 62 // When 63 63 boolean patternContained = pattern.containedIn(taskTree); … … 84 84 "}"; 85 85 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 86 UsagePatternBuilder builder = new UsagePatternBuilder();87 UsagePattern startsWithPattern = builder.concernedNode(ITERATION).contains(MOUSE_CLICK).build();88 UsagePattern containedPattern = builder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build();89 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).contains(TEXT_INPUT).build();90 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containedPattern).endsWith(endsWithPattern).build();86 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 87 InteractionPattern startsWithPattern = builder.concernedNode(ITERATION).contains(MOUSE_CLICK).build(); 88 InteractionPattern containedPattern = builder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 89 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).contains(TEXT_INPUT).build(); 90 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containedPattern).endsWith(endsWithPattern).build(); 91 91 // When 92 92 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsAndEndsWithPatternTest.java
r1170 r1205 25 25 26 26 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;28 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 28 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 29 29 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 30 30 … … 59 59 "}"; 60 60 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 61 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();62 UsagePattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build();63 UsagePattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();64 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).endsWith(endsWithPattern).build();61 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 62 InteractionPattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build(); 63 InteractionPattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 64 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).endsWith(endsWithPattern).build(); 65 65 // When 66 66 boolean patternContained = pattern.containedIn(taskTree); … … 90 90 "}"; 91 91 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 92 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();93 UsagePattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build();94 UsagePattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();95 UsagePattern pattern = patternBuilder.concernedNode(ITERATION).startsWith(endsWithPattern).endsWith(startsWithPattern).build();92 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 93 InteractionPattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build(); 94 InteractionPattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 95 InteractionPattern pattern = patternBuilder.concernedNode(ITERATION).startsWith(endsWithPattern).endsWith(startsWithPattern).build(); 96 96 // When 97 97 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithEventAndContainsEventTest.java
r1170 r1205 23 23 24 24 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 25 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;25 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 27 27 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 28 28 … … 51 51 "}"; 52 52 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 53 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).build();53 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).build(); 54 54 // When 55 55 boolean patternContained = pattern.containedIn(taskTree); … … 82 82 "}"; 83 83 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 84 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).build();84 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).build(); 85 85 // When 86 86 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithEventAndContainsPatternTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 44 44 " TextInput t1 {}" + 45 45 " Selection sel1 {" + 46 " Sequence seq 1{" +46 " Sequence seq2 {" + 47 47 " MouseClick t2 {}" + 48 48 " }" + 49 49 " }" + 50 50 " Selection sel1 {" + 51 " Sequence seq1 {" + 52 " TextInput t3 {}" + 51 " Sequence seq3 {" + 52 " EventTask t3 {}" + 53 " MouseClick t5 {}" + 53 54 " }" + 54 55 " }" + … … 56 57 "}"; 57 58 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 58 UsagePatternBuilder builder = new UsagePatternBuilder();59 UsagePattern containedPattern = builder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).build();60 UsagePattern pattern = builder.concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(containedPattern).build();59 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 60 InteractionPattern endsWithPattern = builder.concernedNode(SELECTION).startsWith(MOUSE_CLICK).build(); 61 InteractionPattern pattern = builder.concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(endsWithPattern).build(); 61 62 // When 62 63 boolean patternContained = pattern.containedIn(taskTree); … … 92 93 "}"; 93 94 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 94 UsagePatternBuilder builder = new UsagePatternBuilder();95 UsagePattern containedPattern = builder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();96 UsagePattern pattern = builder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).contains(containedPattern).build();95 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 96 InteractionPattern endsWithPattern = builder.concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 97 InteractionPattern pattern = builder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(endsWithPattern).build(); 97 98 // When 98 99 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithEventAndEndsWithPatternTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 50 50 "}"; 51 51 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 52 UsagePatternBuilder builder = new UsagePatternBuilder();53 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build();54 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(endsWithPattern).build();52 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 53 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build(); 54 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(endsWithPattern).build(); 55 55 // When 56 56 boolean patternContained = pattern.containedIn(taskTree); … … 72 72 "}"; 73 73 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 74 UsagePatternBuilder builder = new UsagePatternBuilder();75 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build();76 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(endsWithPattern).build();74 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 75 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build(); 76 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(endsWithPattern).build(); 77 77 // When 78 78 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithEventContainsEventEndsWithPatternTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 50 50 "}"; 51 51 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 52 UsagePatternBuilder builder = new UsagePatternBuilder();53 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build();54 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(endsWithPattern).build();52 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 53 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build(); 54 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(endsWithPattern).build(); 55 55 // When 56 56 boolean patternContained = pattern.containedIn(taskTree); … … 72 72 "}"; 73 73 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 74 UsagePatternBuilder builder = new UsagePatternBuilder();75 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build();76 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(endsWithPattern).build();74 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 75 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build(); 76 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).endsWith(endsWithPattern).build(); 77 77 // When 78 78 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithEventContainsPatternAndEndsWithEventTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 52 52 " MouseClick t2 {}" + 53 53 " }" + 54 " }" +55 " TextInput t3{}" +56 " MouseClick t2 {}" +57 " Iteration iter1 {" +58 " TextInput t4 {}" +54 " TextInput t3 {}" + 55 " MouseClick t2 {}" + 56 " Iteration iter1 {" + 57 " TextInput t4 {}" + 58 " }" + 59 59 " }" + 60 60 "}"; 61 61 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 62 UsagePatternBuilder builder = new UsagePatternBuilder();63 UsagePattern containedPattern = builder.concernedNode(SELECTION).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build();64 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(containedPattern).endsWith(TEXT_INPUT).build();62 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 63 InteractionPattern containedPattern = builder.concernedNode(SELECTION).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 64 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(containedPattern).endsWith(TEXT_INPUT).build(); 65 65 // When 66 66 boolean patternContained = pattern.containedIn(taskTree); … … 92 92 "}"; 93 93 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 94 UsagePatternBuilder builder = new UsagePatternBuilder();95 UsagePattern containedPattern = builder.concernedNode(SELECTION).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build();96 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(containedPattern).endsWith(TEXT_INPUT).build();94 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 95 InteractionPattern containedPattern = builder.concernedNode(SELECTION).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 96 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(containedPattern).endsWith(TEXT_INPUT).build(); 97 97 // When 98 98 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithEventContainsPatternAndEndsWithPatternTest.java
r1170 r1205 25 25 26 26 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;28 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 28 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 29 29 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 30 30 … … 61 61 "}"; 62 62 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 63 UsagePatternBuilder builder = new UsagePatternBuilder();64 UsagePattern containedPattern = builder.concernedNode(SELECTION).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build();65 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build();66 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(containedPattern).endsWith(endsWithPattern).build();63 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 64 InteractionPattern containedPattern = builder.concernedNode(SELECTION).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 65 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build(); 66 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(containedPattern).endsWith(endsWithPattern).build(); 67 67 // When 68 68 boolean patternContained = pattern.containedIn(taskTree); … … 91 91 "}"; 92 92 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 93 UsagePatternBuilder builder = new UsagePatternBuilder();94 UsagePattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build();95 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(endsWithPattern).build();93 InteractionPatternBuilder builder = new InteractionPatternBuilder(); 94 InteractionPattern endsWithPattern = builder.concernedNode(ITERATION).startsWith(MOUSE_CLICK).build(); 95 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).endsWith(endsWithPattern).build(); 96 96 // When 97 97 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithEventTest.java
r1170 r1205 22 22 23 23 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 24 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;25 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;24 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 25 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 26 26 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 27 27 … … 50 50 "}"; 51 51 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 52 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).build();52 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).build(); 53 53 // When 54 54 boolean patternContained = pattern.containedIn(taskTree); … … 71 71 "}"; 72 72 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 73 UsagePattern pattern = new UsagePatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).build();73 InteractionPattern pattern = new InteractionPatternBuilder().concernedNode(SEQUENCE).startsWith(TEXT_INPUT).build(); 74 74 // When 75 75 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithPatternAndContainsEventTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 54 54 "}"; 55 55 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 56 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();57 UsagePattern startsWithPattern = patternBuilder.concernedNode(ITERATION).startsWith(TEXT_INPUT).build();58 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).build();56 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 57 InteractionPattern startsWithPattern = patternBuilder.concernedNode(ITERATION).startsWith(TEXT_INPUT).build(); 58 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).build(); 59 59 // When 60 60 boolean patternContained = pattern.containedIn(taskTree); … … 79 79 "}"; 80 80 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 81 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();82 UsagePattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(TEXT_INPUT).build();83 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).build();81 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 82 InteractionPattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(TEXT_INPUT).build(); 83 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).build(); 84 84 // When 85 85 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithPatternAndContainsPatternTest.java
r1170 r1205 25 25 26 26 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;28 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 28 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 29 29 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 30 30 … … 62 62 "}"; 63 63 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 64 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();65 UsagePattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build();66 UsagePattern containedPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();67 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containedPattern).build();64 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 65 InteractionPattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build(); 66 InteractionPattern containedPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 67 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containedPattern).build(); 68 68 // When 69 69 boolean patternContained = pattern.containedIn(taskTree); … … 96 96 "}"; 97 97 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 98 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();99 UsagePattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build();100 UsagePattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();101 UsagePattern pattern = patternBuilder.concernedNode(ITERATION).startsWith(endsWithPattern).endsWith(startsWithPattern).build();98 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 99 InteractionPattern startsWithPattern = patternBuilder.concernedNode(ITERATION).contains(MOUSE_CLICK).build(); 100 InteractionPattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 101 InteractionPattern pattern = patternBuilder.concernedNode(ITERATION).startsWith(endsWithPattern).endsWith(startsWithPattern).build(); 102 102 // When 103 103 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithPatternAndEndsWithEventTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 59 59 "}"; 60 60 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 61 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();62 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();63 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).endsWith(TEXT_INPUT).build();61 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 62 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 63 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).endsWith(TEXT_INPUT).build(); 64 64 // When 65 65 boolean patternContained = pattern.containedIn(taskTree); … … 90 90 "}"; 91 91 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 92 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();93 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();94 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).endsWith(TEXT_INPUT).build();92 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 93 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 94 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).endsWith(TEXT_INPUT).build(); 95 95 // When 96 96 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithPatternContainsEventAndEndsWithEventTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 44 44 " Selection sel1 {" + 45 45 " Sequence seq2 {" + 46 " TextInput target 4{}" +46 " TextInput target1 {}" + 47 47 " MouseClick target2 {}" + 48 48 " }" + … … 50 50 " Selection sel1 {" + 51 51 " Sequence seq3 {" + 52 " TextInput target 4{}" +53 " EventTask target 2{}" +52 " TextInput target3 {}" + 53 " EventTask target4 {}" + 54 54 " }" + 55 55 " }" + 56 " MouseClick target 2{}" +57 " TextInput target 3{}" +56 " MouseClick target5 {}" + 57 " TextInput target6 {}" + 58 58 " }" + 59 59 "}"; 60 60 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 61 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();62 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();63 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build();61 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 62 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 63 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 64 64 // When 65 65 boolean patternContained = pattern.containedIn(taskTree); … … 90 90 "}"; 91 91 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 92 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();93 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();94 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build();92 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 93 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 94 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 95 95 // When 96 96 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithPatternContainsEventAndEndsWithPatternTest.java
r1170 r1205 16 16 17 17 import static de.ugoe.cs.autoquest.usability.tasktree.filters.EventTypeFilter.MOUSE_CLICK; 18 import static de.ugoe.cs.autoquest.usability.tasktree.filters.EventTypeFilter.SCROLL; 18 19 import static de.ugoe.cs.autoquest.usability.tasktree.filters.EventTypeFilter.TEXT_INPUT; 19 20 import static de.ugoe.cs.autoquest.usability.tasktree.filters.TaskTypeFilter.SELECTION; … … 24 25 25 26 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 28 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 29 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 30 … … 54 55 " }" + 55 56 " }" + 56 " }" +57 " MouseClick target2{}" +58 " TextInput target3 {}" +59 " Selection sel2{" +60 " Sequence seq4 {" +61 " TextInput target4{}" +62 " MouseClick target2 {}" +57 " MouseClick target2 {}" + 58 " TextInput target3 {}" + 59 " Selection sel2 {" + 60 " Sequence seq5 {" + 61 " TextInput target4 {}" + 62 " MouseClick target2 {}" + 63 " }" + 63 64 " }" + 64 " }" +65 " Selection sel2{" +66 " Sequence seq5 {" +67 " TextInput target4{}" +68 " EventTask target2 {}" +65 " Selection sel2 {" + 66 " Sequence seq6 {" + 67 " TextInput target4 {}" + 68 " EventTask target2 {}" + 69 " }" + 69 70 " }" + 70 71 " }" + 71 72 "}"; 72 73 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 73 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();74 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();75 UsagePattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();76 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).endsWith(endsWithPattern).build();74 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 75 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 76 InteractionPattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 77 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).endsWith(endsWithPattern).build(); 77 78 // When 78 79 boolean patternContained = pattern.containedIn(taskTree); … … 89 90 " Sequence seq2 {" + 90 91 " TextInput target4 {}" + 91 " MouseClick target 2{}" +92 " MouseClick target3 {}" + 92 93 " }" + 93 94 " }" + … … 98 99 " }" + 99 100 " }" + 100 " }" +101 " EventTask target2{}" +102 " TextInput target3 {}" +103 " Selection sel2{" +104 " Sequence seq4 {" +105 " TextInput target4{}" +106 " MouseClick target2 {}" +101 " EventTask target2 {}" + 102 " TextInput target1 {}" + 103 " Selection sel2 {" + 104 " Sequence seq5 {" + 105 " TextInput target4 {}" + 106 " MouseClick target3 {}" + 107 " }" + 107 108 " }" + 108 " }" +109 " Selection sel2{" +110 " Sequence seq5 {" +111 " TextInput target4{}" +112 " EventTask target2 {}" +109 " Selection sel2 {" + 110 " Sequence seq6 {" + 111 " TextInput target4 {}" + 112 " EventTask target2 {}" + 113 " }" + 113 114 " }" + 114 115 " }" + 115 116 "}"; 116 117 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 117 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();118 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();119 UsagePattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();120 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(MOUSE_CLICK).endsWith(endsWithPattern).build();118 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 119 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 120 InteractionPattern endsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 121 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(SCROLL).endsWith(endsWithPattern).build(); 121 122 // When 122 123 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithPatternContainsPatternAndEndsWithEventTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 45 45 " Sequence seq2 {" + 46 46 " TextInput target4 {}" + 47 " MouseClick target 2{}" +47 " MouseClick target1 {}" + 48 48 " }" + 49 49 " }" + 50 50 " Selection sel1 {" + 51 51 " Sequence seq3 {" + 52 " TextInput target 4{}" +53 " EventTask target 2{}" +52 " TextInput target3 {}" + 53 " EventTask target5 {}" + 54 54 " }" + 55 55 " }" + 56 " Sequence seq4 {" + 57 " MouseClick target6 {}" + 58 " EventTask t5 {}" + 59 " }" + 60 " TextInput target7 {}" + 56 61 " }" + 57 " Sequence seq4 {" +58 " MouseClick target2 {}" +59 " EventTask t5 {}" +60 " }" +61 " TextInput target3 {}" +62 62 "}"; 63 63 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 64 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();65 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();66 UsagePattern containsPattern = patternBuilder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).build();67 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containsPattern).endsWith(TEXT_INPUT).build();64 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 65 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 66 InteractionPattern containsPattern = patternBuilder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).build(); 67 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containsPattern).endsWith(TEXT_INPUT).build(); 68 68 // When 69 69 boolean patternContained = pattern.containedIn(taskTree); … … 97 97 "}"; 98 98 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 99 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();100 UsagePattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build();101 UsagePattern containsPattern = patternBuilder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build();102 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containsPattern).endsWith(TEXT_INPUT).build();99 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 100 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SELECTION).startsWith(TEXT_INPUT).endsWith(MOUSE_CLICK).build(); 101 InteractionPattern containsPattern = patternBuilder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 102 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).contains(containsPattern).endsWith(TEXT_INPUT).build(); 103 103 // When 104 104 boolean patternContained = pattern.containedIn(taskTree); -
trunk/autoquest-core-usability-evaluation-test/src/main/java/de/ugoe/cs/autoquest/usability/rules/patterns/visitors/startswith/StartsWithPatternTest.java
r1170 r1205 24 24 25 25 import de.ugoe.cs.autoquest.tasktrees.treeifc.ITaskModel; 26 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePattern;27 import de.ugoe.cs.autoquest.usability.rules.patterns. UsagePatternBuilder;26 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPattern; 27 import de.ugoe.cs.autoquest.usability.rules.patterns.InteractionPatternBuilder; 28 28 import de.ugoe.cs.autoquest.usability.testutil.GenerateTaskModelUtil; 29 29 … … 57 57 "}"; 58 58 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 59 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();60 UsagePattern startsWithPattern = patternBuilder.concernedNode(ITERATION).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).build();61 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).build();59 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 60 InteractionPattern startsWithPattern = patternBuilder.concernedNode(ITERATION).startsWith(TEXT_INPUT).contains(MOUSE_CLICK).build(); 61 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).build(); 62 62 // When 63 63 boolean patternContained = pattern.containedIn(taskTree); … … 86 86 "}"; 87 87 ITaskModel taskTree = GenerateTaskModelUtil.getTaskModelFromSpec(spec); 88 UsagePatternBuilder patternBuilder = new UsagePatternBuilder();89 UsagePattern startsWithPattern = patternBuilder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build();90 UsagePattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).build();88 InteractionPatternBuilder patternBuilder = new InteractionPatternBuilder(); 89 InteractionPattern startsWithPattern = patternBuilder.concernedNode(SEQUENCE).startsWith(MOUSE_CLICK).endsWith(TEXT_INPUT).build(); 90 InteractionPattern pattern = patternBuilder.concernedNode(SEQUENCE).startsWith(startsWithPattern).build(); 91 91 // When 92 92 boolean patternContained = pattern.containedIn(taskTree);
Note: See TracChangeset
for help on using the changeset viewer.