You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@any23.apache.org by ha...@apache.org on 2018/04/13 13:33:32 UTC

any23 git commit: ANY23-237 added test case to ensure no regression

Repository: any23
Updated Branches:
  refs/heads/master d9bff00e0 -> b13472c20


ANY23-237 added test case to ensure no regression


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

Branch: refs/heads/master
Commit: b13472c202f23d9faacafdaa9bd29fbfddfcfe0b
Parents: d9bff00
Author: Hans <fi...@gmail.com>
Authored: Fri Apr 13 08:25:04 2018 -0500
Committer: Hans <fi...@gmail.com>
Committed: Fri Apr 13 08:25:04 2018 -0500

----------------------------------------------------------------------
 .../extractor/rdfa/RDFa11ExtractorTest.java     |  8 +++
 .../any23/extractor/rdfa/RDFaExtractorTest.java |  6 +--
 .../src/test/resources/html/rdfa/0087.xhtml     | 53 ++++++++++++++++++++
 3 files changed, 64 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/any23/blob/b13472c2/core/src/test/java/org/apache/any23/extractor/rdfa/RDFa11ExtractorTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/any23/extractor/rdfa/RDFa11ExtractorTest.java b/core/src/test/java/org/apache/any23/extractor/rdfa/RDFa11ExtractorTest.java
index c0767c9..7849f50 100644
--- a/core/src/test/java/org/apache/any23/extractor/rdfa/RDFa11ExtractorTest.java
+++ b/core/src/test/java/org/apache/any23/extractor/rdfa/RDFa11ExtractorTest.java
@@ -71,6 +71,14 @@ public class RDFa11ExtractorTest extends AbstractRDFaExtractorTestCase {
     }
 
     @Test
+    public void test0087() {
+        assertExtract("/html/rdfa/0087.xhtml");
+        assertModelNotEmpty();
+        assertStatementsSize(null, null, null, 24);
+        assertContains(RDFUtils.iri("http://www.w3.org/1999/xhtml/vocab#stylesheet"), RDFUtils.iri("http://example.org/stylesheet"));
+    }
+
+    @Test
     public void testIssue326() {
         assertExtract("/html/rdfa/rdfa-issue326-and-267.html");
     }

http://git-wip-us.apache.org/repos/asf/any23/blob/b13472c2/core/src/test/java/org/apache/any23/extractor/rdfa/RDFaExtractorTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/any23/extractor/rdfa/RDFaExtractorTest.java b/core/src/test/java/org/apache/any23/extractor/rdfa/RDFaExtractorTest.java
index 680fe47..0ca6f0f 100644
--- a/core/src/test/java/org/apache/any23/extractor/rdfa/RDFaExtractorTest.java
+++ b/core/src/test/java/org/apache/any23/extractor/rdfa/RDFaExtractorTest.java
@@ -38,10 +38,10 @@ public class RDFaExtractorTest extends AbstractRDFaExtractorTestCase {
      * It checks if the extraction is the same when the namespaces are defined in <i>RDFa1.0</i> or
      * <i>RDFa1.1</i> respectively.
      *
-     * @throws org.openrdf.repository.RepositoryException
+     * @throws org.eclipse.rdf4j.repository.RepositoryException
      * @throws java.io.IOException
-     * @throws org.openrdf.rio.RDFHandlerException
-     * @throws org.openrdf.rio.RDFParseException
+     * @throws org.eclipse.rdf4j.rio.RDFHandlerException
+     * @throws org.eclipse.rdf4j.rio.RDFParseException
      */
     @Test
     public void testRDFa11PrefixBackwardCompatibility()

http://git-wip-us.apache.org/repos/asf/any23/blob/b13472c2/test-resources/src/test/resources/html/rdfa/0087.xhtml
----------------------------------------------------------------------
diff --git a/test-resources/src/test/resources/html/rdfa/0087.xhtml b/test-resources/src/test/resources/html/rdfa/0087.xhtml
new file mode 100644
index 0000000..ff8de08
--- /dev/null
+++ b/test-resources/src/test/resources/html/rdfa/0087.xhtml
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You 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.
+-->
+
+<!--  Test 0087+xhtml1 from http://rdfa.info/test-suite/ -->
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.1//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-2.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" version="XHTML+RDFa 1.1">
+<head>
+    <title>Test 0087</title>
+</head>
+<body>
+<p>
+    <a rel=":alternate" href="http://example.org/alternate">alternate</a>
+    <a rel=":appendix" href="http://example.org/appendix">appendix</a>
+    <a rel=":bookmark" href="http://example.org/bookmark">bookmark</a>
+    <a rel=":cite" href="http://example.org/cite">cite</a>
+    <a rel=":chapter" href="http://example.org/chapter">chapter</a>
+    <a rel=":contents" href="http://example.org/contents">contents</a>
+    <a rel=":copyright" href="http://example.org/copyright">copyright</a>
+    <a rel=":glossary" href="http://example.org/glossary">glossary</a>
+    <a rel=":help" href="http://example.org/help">help</a>
+    <a rel=":icon" href="http://example.org/icon">icon</a>
+    <a rel=":index" href="http://example.org/index">index</a>
+    <a rel=":first" href="http://example.org/first">first</a>
+    <a rel=":last" href="http://example.org/last">last</a>
+    <a rel=":license" href="http://example.org/license">license</a>
+    <a rel=":meta" href="http://example.org/meta">meta</a>
+    <a rel=":next" href="http://example.org/next">next</a>
+    <a rel=":p3pv1" href="http://example.org/p3pv1">p3pv1</a>
+    <a rel=":prev" href="http://example.org/prev">prev</a>
+    <a rel=":role" href="http://example.org/role">role</a>
+    <a rel=":section" href="http://example.org/section">section</a>
+    <a rel=":subsection" href="http://example.org/subsection">subsection</a>
+    <a rel=":start" href="http://example.org/start">start</a>
+    <a rel=":stylesheet" href="http://example.org/stylesheet">stylesheet</a>
+    <a rel=":up" href="http://example.org/up">up</a>
+</p>
+</body>
+</html>
\ No newline at end of file