Fixed distancequerychecks
diff --git a/src/test/java/de/ids_mannheim/korap/index/TestMultipleDistanceIndex.java b/src/test/java/de/ids_mannheim/korap/index/TestMultipleDistanceIndex.java
index 61035f7..98b1e9b 100644
--- a/src/test/java/de/ids_mannheim/korap/index/TestMultipleDistanceIndex.java
+++ b/src/test/java/de/ids_mannheim/korap/index/TestMultipleDistanceIndex.java
@@ -116,7 +116,7 @@
  	    SpanQuery mdq;	   
 		mdq = createQuery("s:b", "s:c", constraints, false);
 		kr = ki.search(mdq, (short) 10);
-		System.out.println(mdq);
+		// System.out.println(mdq);
 		
 		assertEquals(3, kr.getTotalResults());
 	    assertEquals(0, kr.getMatch(0).getStartPos());
diff --git a/src/test/java/de/ids_mannheim/korap/query/TestKorapQueryJSON.java b/src/test/java/de/ids_mannheim/korap/query/TestKorapQueryJSON.java
index 670c655..979dacd 100644
--- a/src/test/java/de/ids_mannheim/korap/query/TestKorapQueryJSON.java
+++ b/src/test/java/de/ids_mannheim/korap/query/TestKorapQueryJSON.java
@@ -193,8 +193,7 @@
 	SpanQueryWrapperInterface sqwi = jsonQuery(getClass().getResource("/queries/cosmas3.json").getFile());
 
 	// "das /+w1:3 Buch"
-	// Todo: Here the serialized constraint information is missing
-	assertEquals(sqwi.toQuery().toString(), "spanDistance(tokens:s:das, tokens:s:Buch)");
+	assertEquals(sqwi.toQuery().toString(), "spanDistance(tokens:s:das, tokens:s:Buch, [(w[1:3], ordered, notExcluded)])");
     };
 
     @Test
@@ -202,8 +201,7 @@
 	SpanQueryWrapperInterface sqwi = jsonQuery(getClass().getResource("/queries/cosmas4.json").getFile());
 
 	// "das /+w1:3,s1 Buch"
-	// Todo: Here the serialized constraint information is missing
-	assertEquals(sqwi.toQuery().toString(), "spanMultipleDistance(tokens:s:das, tokens:s:Buch)");
+	assertEquals(sqwi.toQuery().toString(), "spanMultipleDistance(tokens:s:das, tokens:s:Buch, [(w[1:3], ordered, notExcluded), (s[1:1], ordered, notExcluded)])");
     };
 
     @Test
diff --git a/src/test/java/de/ids_mannheim/korap/query/TestSpanSequenceQuery.java b/src/test/java/de/ids_mannheim/korap/query/TestSpanSequenceQuery.java
index f0afe57..9d56d78 100644
--- a/src/test/java/de/ids_mannheim/korap/query/TestSpanSequenceQuery.java
+++ b/src/test/java/de/ids_mannheim/korap/query/TestSpanSequenceQuery.java
@@ -36,17 +36,13 @@
 	sssq.withConstraint(2,3);
 	assertTrue(sssq.hasConstraints());
 
-	// Todo: This does not mention the constraint!
-	assertEquals("spanDistance(field:a, field:b)", sssq.toQuery().toString());
+	assertEquals("spanDistance(field:a, field:b, [(w[2:3], ordered, notExcluded)])", sssq.toQuery().toString());
 
 	sssq.append("c");
-	// Todo: This does not mention the constraint!
-	assertEquals("spanDistance(spanDistance(field:a, field:b), field:c)", sssq.toQuery().toString());
+	assertEquals("spanDistance(spanDistance(field:a, field:b, [(w[2:3], ordered, notExcluded)]), field:c, [(w[2:3], ordered, notExcluded)])", sssq.toQuery().toString());
 	sssq.withConstraint(6,8, "s");
 	assertTrue(sssq.hasConstraints());
 
-
-	// Todo: This does not mention the constraint!
-	assertEquals("spanMultipleDistance(spanMultipleDistance(field:a, field:b), field:c)", sssq.toQuery().toString());
+	assertEquals("spanMultipleDistance(spanMultipleDistance(field:a, field:b, [(w[2:3], ordered, notExcluded), (s[6:8], ordered, notExcluded)]), field:c, [(w[2:3], ordered, notExcluded), (s[6:8], ordered, notExcluded)])", sssq.toQuery().toString());
     };
 };
diff --git a/src/test/resources/queries/bsp11.jsonld b/src/test/resources/queries/bsp11.jsonld
index f5b9484..8a056f4 100644
--- a/src/test/resources/queries/bsp11.jsonld
+++ b/src/test/resources/queries/bsp11.jsonld
@@ -108,7 +108,8 @@
       "operands": [
         {
           "@type": "korap:term", 
-          "layer": "base",
+	  "foundry" : "mate",
+          "layer": "lemma",
           "key" : "Katze", 
           "match": "match:ne"
         },