jena-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From o...@apache.org
Subject [1/2] jena git commit: JENA-1159: failing unit test
Date Tue, 29 Mar 2016 12:19:43 GMT
Repository: jena
Updated Branches:
  refs/heads/master 1132a36bd -> ce467aa8c


JENA-1159: failing unit test


Project: http://git-wip-us.apache.org/repos/asf/jena/repo
Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/a0b16d42
Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/a0b16d42
Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/a0b16d42

Branch: refs/heads/master
Commit: a0b16d42f0a4e5557d6bef78468f32f07f28380b
Parents: 1132a36
Author: Osma Suominen <osma@apache.org>
Authored: Tue Mar 29 15:02:24 2016 +0300
Committer: Osma Suominen <osma@apache.org>
Committed: Tue Mar 29 15:02:24 2016 +0300

----------------------------------------------------------------------
 ...DatasetWithLuceneTextIndexWithLangField.java | 28 ++++++++++++++++++++
 1 file changed, 28 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jena/blob/a0b16d42/jena-text/src/test/java/org/apache/jena/query/text/TestDatasetWithLuceneTextIndexWithLangField.java
----------------------------------------------------------------------
diff --git a/jena-text/src/test/java/org/apache/jena/query/text/TestDatasetWithLuceneTextIndexWithLangField.java
b/jena-text/src/test/java/org/apache/jena/query/text/TestDatasetWithLuceneTextIndexWithLangField.java
index f1e7e08..2fa04a9 100644
--- a/jena-text/src/test/java/org/apache/jena/query/text/TestDatasetWithLuceneTextIndexWithLangField.java
+++ b/jena-text/src/test/java/org/apache/jena/query/text/TestDatasetWithLuceneTextIndexWithLangField.java
@@ -123,4 +123,32 @@ public class TestDatasetWithLuceneTextIndexWithLangField extends AbstractTestDat
         expectedURIs.addAll( Arrays.asList("http://example.org/data/resource/ParisInEnglish"))
;
         doTestSearch(turtle, queryString, expectedURIs);
     }
+
+    @Test
+    public void testLiteralLanguageSearchItalian(){
+        final String turtle = StrUtils.strjoinNL(
+                TURTLE_PROLOG,
+                "<" + RESOURCE_BASE + "ParisInEnglish>",
+                "  rdfs:label 'Paris, capital of France'@en",
+                ".",
+                TURTLE_PROLOG,
+                "<" + RESOURCE_BASE + "ParisInItalian>",
+                "  rdfs:label \"Paris รจ l'endonimo francese di Parigi, capitale della Francia\"@it",
+                ".",
+                TURTLE_PROLOG,
+                "<" + RESOURCE_BASE + "ParisInFrench>",
+                "  rdfs:label 'Paris, capitale de la France'@fr",
+                "."
+        );
+        String queryString = StrUtils.strjoinNL(
+                QUERY_PROLOG,
+                "SELECT ?s",
+                "WHERE {",
+                "    ?s text:query ( rdfs:label 'paris' 'lang:it' 10 ) .",
+                "}"
+        );
+        Set<String> expectedURIs = new HashSet<>() ;
+        expectedURIs.addAll( Arrays.asList("http://example.org/data/resource/ParisInItalian"))
;
+        doTestSearch(turtle, queryString, expectedURIs);
+    }
 }


Mime
View raw message