Index: branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/alignment/algorithms/NumberSequenceTest.java
===================================================================
--- branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/alignment/algorithms/NumberSequenceTest.java	(revision 1649)
+++ branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/alignment/algorithms/NumberSequenceTest.java	(revision 1650)
@@ -14,19 +14,22 @@
 		}
 		
-		int[] pat1 = new int[]{2,3,4};
-		int[] pat2 = new int[]{2,3,4};
+		int[] pat1  = new int[]{2,3,4};
+		int[] pat2  = new int[]{2,3,4};
 		
-		int[] pat3 = new int[]{5,-1,7};
-		int[] pat4 = new int[]{1,2,3};
+		int[] pat3  = new int[]{5,-1,6};
+		int[] pat4  = new int[]{1,2,3};
 		
-		int[] pat5 = new int[]{-1,-1,-1};
+		int[] pat5  = new int[]{-1,-1,-1};
 		
-		int[] pat6 = new int[]{10,11,12};
+		int[] pat6  = new int[]{10,11,12};
 		
-		int[] pat7 = new int[]{8,9,10};
-		int[] pat8 = new int[]{7,6,5};
+		int[] pat7  = new int[]{8,9,10};
+		int[] pat8  = new int[]{7,6,5};
 		
-		int[] pat9 = new int[]{0};
+		int[] pat9  = new int[]{0};
 		int[] pat10 = new int[]{1};
+		
+		int[] pat11 = new int[]{5,-1,-1,6};
+		int[] pat12 = new int[]{10,12,12,12}; 
 		
 		
@@ -49,6 +52,7 @@
 		
 		assertEquals(Integer.valueOf(1),ns.containsPattern(pattern).get(0));
+		assertEquals(2,ns.containsPattern(pattern).size());
 		assertEquals(Integer.valueOf(5),ns.containsPattern(pattern).get(1));
-		assertEquals(2,ns.containsPattern(pattern).size());
+		
 	
 		firstpattern.setSequence(pat5);
@@ -69,4 +73,10 @@
 		assertEquals(Integer.valueOf(1),ns.containsPattern(pattern).get(1));
 		assertEquals(2,ns.containsPattern(pattern).size());
+		
+		firstpattern.setSequence(pat11);
+		secondpattern.setSequence(pat12);
+		assertEquals(1,ns.containsPattern(pattern).size());
+		assertEquals(Integer.valueOf(5),ns.containsPattern(pattern).get(0));
+		
 	
 	}
Index: branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/SequenceForTaskDetectionRuleAlignmentTest.java
===================================================================
--- branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/SequenceForTaskDetectionRuleAlignmentTest.java	(revision 1650)
+++ branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/SequenceForTaskDetectionRuleAlignmentTest.java	(revision 1650)
@@ -0,0 +1,176 @@
+//   Copyright 2012 Georg-August-Universität Göttingen, Germany
+//
+//   Licensed under the Apache License, Version 2.0 (the "License");
+//   you may not use this file except in compliance with the License.
+//   You may obtain a copy of the License at
+//
+//       http://www.apache.org/licenses/LICENSE-2.0
+//
+//   Unless required by applicable law or agreed to in writing, software
+//   distributed under the License is distributed on an "AS IS" BASIS,
+//   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//   See the License for the specific language governing permissions and
+//   limitations under the License.
+
+package de.ugoe.cs.autoquest.tasktrees.temporalrelation;
+
+import org.junit.Test;
+
+/**
+ * @author Patrick Harms
+ */
+public class SequenceForTaskDetectionRuleAlignmentTest extends AbstractTemporalRelationshipTC {
+
+    /**
+     *
+     */
+    @Test
+    public void test_TaskDetection_01() throws Exception {
+        String input =
+            "UserSession {" +
+            "  Event noise0 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event action3 {}" +
+            "  Event action4 {}" +
+            "  Event noise1 {}" +
+            "  Event noise2 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event action3 {}" +
+            "  Event action4 {}" +
+            "  Event noise3 {}" +
+            "  Event noise4 {}" +
+            "  Event noise5 {}" +
+            "  Event noise6 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event action3 {}" +
+            "  Event action4 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event action3 {}" +
+            "  Event action4 {}" +
+            "  Event noise7 {}" +
+            "}";
+
+        String output =
+            "UserSession {" +
+            "  Event noise0 {}" +
+            "  Iteration iteration1 {" +
+            "    Sequence sequence1 {" +
+            "      Event action1 {}" +
+            "      Event action2 {}" +
+            "      Event action3 {}" +
+            "      Event action4 {}" +
+            "    }" +
+            "  }" +
+            "  Event noise1 {}" +
+            "  Event noise2 {}" +
+            "  Iteration iteration1 {" +
+            "    Sequence sequence1 {" +
+            "      Event action1 {}" +
+            "      Event action2 {}" +
+            "      Event action3 {}" +
+            "      Event action4 {}" +
+            "    }" +
+            "  }" +
+            "  Event noise3 {}" +
+            "  Event noise4 {}" +
+            "  Event noise5 {}" +
+            "  Event noise6 {}" +
+            "  Iteration iteration1 {" +
+            "    Sequence sequence1 {" +
+            "      Event action1 {}" +
+            "      Event action2 {}" +
+            "      Event action3 {}" +
+            "      Event action4 {}" +
+            "    }" +
+            "    Sequence sequence1 {" +
+            "      Event action1 {}" +
+            "      Event action2 {}" +
+            "      Event action3 {}" +
+            "      Event action4 {}" +
+            "    }" +
+            "  }" +
+            "  Event noise7 {}" +
+            "}";
+
+        applySessionScopeRule(SequenceForTaskDetectionRule.class, input, output);
+    }
+
+    /**
+     *
+     */
+    @Test
+    public void test_TaskDetection_02() throws Exception {
+        String input =
+            "UserSession {" +
+            "  Event noise0 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event noise1 {}" +
+            "  Event noise2 {}" +
+            "  Event action3 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event action4 {}" +
+            "  Event noise3 {}" +
+            "  Event noise4 {}" +
+            "  Event noise5 {}" +
+            "  Event noise6 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event action3 {}" +
+            "  Event action4 {}" +
+            "  Event action1 {}" +
+            "  Event action2 {}" +
+            "  Event action3 {}" +
+            "  Event action4 {}" +
+            "  Event noise7 {}" +
+            "}";
+
+        String output =
+            "UserSession {" +
+            "  Event noise0 {}" +
+            "  Sequence sequence1 {" +
+            "    Event action1 {}" +
+            "    Event action2 {}" +
+            "  }" +
+            "  Event noise1 {}" +
+            "  Event noise2 {}" +
+            "  Event action3 {}" +
+            "  Sequence sequence1 {" +
+            "    Event action1 {}" +
+            "    Event action2 {}" +
+            "  }" +
+            "  Event action4 {}" +
+            "  Event noise3 {}" +
+            "  Event noise4 {}" +
+            "  Event noise5 {}" +
+            "  Event noise6 {}" +
+            "  Iteration iteration1 {" +
+            "    Sequence sequence3 {" +
+            "      Sequence sequence1 {" +
+            "        Event action1 {}" +
+            "        Event action2 {}" +
+            "      }" +
+            "      Event action3 {}" +
+            "      Event action4 {}" +
+            "    }" +
+            "    Sequence sequence3 {" +
+            "      Sequence sequence1 {" +
+            "        Event action1 {}" +
+            "        Event action2 {}" +
+            "      }" +
+            "      Event action3 {}" +
+            "      Event action4 {}" +
+            "    }" +
+            "  }" +
+            "  Event noise7 {}" +
+            "}";
+
+        applySessionScopeRule(SequenceForTaskDetectionRule.class, input, output);
+    }
+
+}
Index: branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/SequenceForTaskDetectionRuleTest.java
===================================================================
--- branches/autoquest-core-tasktrees-alignment-test/src/test/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/SequenceForTaskDetectionRuleTest.java	(revision 1649)
+++ 	(revision )
@@ -1,176 +1,0 @@
-//   Copyright 2012 Georg-August-Universität Göttingen, Germany
-//
-//   Licensed under the Apache License, Version 2.0 (the "License");
-//   you may not use this file except in compliance with the License.
-//   You may obtain a copy of the License at
-//
-//       http://www.apache.org/licenses/LICENSE-2.0
-//
-//   Unless required by applicable law or agreed to in writing, software
-//   distributed under the License is distributed on an "AS IS" BASIS,
-//   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//   See the License for the specific language governing permissions and
-//   limitations under the License.
-
-package de.ugoe.cs.autoquest.tasktrees.temporalrelation;
-
-import org.junit.Test;
-
-/**
- * @author Patrick Harms
- */
-public class SequenceForTaskDetectionRuleTest extends AbstractTemporalRelationshipTC {
-
-    /**
-     *
-     */
-    @Test
-    public void test_TaskDetection_01() throws Exception {
-        String input =
-            "UserSession {" +
-            "  Event noise0 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event action3 {}" +
-            "  Event action4 {}" +
-            "  Event noise1 {}" +
-            "  Event noise2 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event action3 {}" +
-            "  Event action4 {}" +
-            "  Event noise3 {}" +
-            "  Event noise4 {}" +
-            "  Event noise5 {}" +
-            "  Event noise6 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event action3 {}" +
-            "  Event action4 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event action3 {}" +
-            "  Event action4 {}" +
-            "  Event noise7 {}" +
-            "}";
-
-        String output =
-            "UserSession {" +
-            "  Event noise0 {}" +
-            "  Iteration iteration1 {" +
-            "    Sequence sequence1 {" +
-            "      Event action1 {}" +
-            "      Event action2 {}" +
-            "      Event action3 {}" +
-            "      Event action4 {}" +
-            "    }" +
-            "  }" +
-            "  Event noise1 {}" +
-            "  Event noise2 {}" +
-            "  Iteration iteration1 {" +
-            "    Sequence sequence1 {" +
-            "      Event action1 {}" +
-            "      Event action2 {}" +
-            "      Event action3 {}" +
-            "      Event action4 {}" +
-            "    }" +
-            "  }" +
-            "  Event noise3 {}" +
-            "  Event noise4 {}" +
-            "  Event noise5 {}" +
-            "  Event noise6 {}" +
-            "  Iteration iteration1 {" +
-            "    Sequence sequence1 {" +
-            "      Event action1 {}" +
-            "      Event action2 {}" +
-            "      Event action3 {}" +
-            "      Event action4 {}" +
-            "    }" +
-            "    Sequence sequence1 {" +
-            "      Event action1 {}" +
-            "      Event action2 {}" +
-            "      Event action3 {}" +
-            "      Event action4 {}" +
-            "    }" +
-            "  }" +
-            "  Event noise7 {}" +
-            "}";
-
-        applySessionScopeRule(SequenceForTaskDetectionRule.class, input, output);
-    }
-
-    /**
-     *
-     */
-    @Test
-    public void test_TaskDetection_02() throws Exception {
-        String input =
-            "UserSession {" +
-            "  Event noise0 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event noise1 {}" +
-            "  Event noise2 {}" +
-            "  Event action3 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event action4 {}" +
-            "  Event noise3 {}" +
-            "  Event noise4 {}" +
-            "  Event noise5 {}" +
-            "  Event noise6 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event action3 {}" +
-            "  Event action4 {}" +
-            "  Event action1 {}" +
-            "  Event action2 {}" +
-            "  Event action3 {}" +
-            "  Event action4 {}" +
-            "  Event noise7 {}" +
-            "}";
-
-        String output =
-            "UserSession {" +
-            "  Event noise0 {}" +
-            "  Sequence sequence1 {" +
-            "    Event action1 {}" +
-            "    Event action2 {}" +
-            "  }" +
-            "  Event noise1 {}" +
-            "  Event noise2 {}" +
-            "  Event action3 {}" +
-            "  Sequence sequence1 {" +
-            "    Event action1 {}" +
-            "    Event action2 {}" +
-            "  }" +
-            "  Event action4 {}" +
-            "  Event noise3 {}" +
-            "  Event noise4 {}" +
-            "  Event noise5 {}" +
-            "  Event noise6 {}" +
-            "  Iteration iteration1 {" +
-            "    Sequence sequence3 {" +
-            "      Sequence sequence1 {" +
-            "        Event action1 {}" +
-            "        Event action2 {}" +
-            "      }" +
-            "      Event action3 {}" +
-            "      Event action4 {}" +
-            "    }" +
-            "    Sequence sequence3 {" +
-            "      Sequence sequence1 {" +
-            "        Event action1 {}" +
-            "        Event action2 {}" +
-            "      }" +
-            "      Event action3 {}" +
-            "      Event action4 {}" +
-            "    }" +
-            "  }" +
-            "  Event noise7 {}" +
-            "}";
-
-        applySessionScopeRule(SequenceForTaskDetectionRule.class, input, output);
-    }
-
-}
