You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by pa...@apache.org on 2016/10/04 21:44:05 UTC
[2/2] groovy git commit: GROOVY-7955: Groovydoc fails to parse Java
source files containing the diamond operator (tweak to allow testing of java
7 diamond operator with 1.6 source compatibility)
GROOVY-7955: Groovydoc fails to parse Java source files containing the diamond operator (tweak to allow testing of java 7 diamond operator with 1.6 source compatibility)
Project: http://git-wip-us.apache.org/repos/asf/groovy/repo
Commit: http://git-wip-us.apache.org/repos/asf/groovy/commit/8cfd70f8
Tree: http://git-wip-us.apache.org/repos/asf/groovy/tree/8cfd70f8
Diff: http://git-wip-us.apache.org/repos/asf/groovy/diff/8cfd70f8
Branch: refs/heads/GROOVY_2_4_X
Commit: 8cfd70f89e96c191da6fb76866806ac3aed3aa4f
Parents: ed1bcec
Author: paulk <pa...@asert.com.au>
Authored: Wed Oct 5 07:43:53 2016 +1000
Committer: paulk <pa...@asert.com.au>
Committed: Wed Oct 5 07:43:53 2016 +1000
----------------------------------------------------------------------
.../tools/groovydoc/GroovyDocToolTest.java | 6 ++---
.../testfiles/JavaClassWithDiamond.java | 26 --------------------
.../testfiles/JavaClassWithDiamond.java | 26 ++++++++++++++++++++
3 files changed, 29 insertions(+), 29 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/groovy/blob/8cfd70f8/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/GroovyDocToolTest.java
----------------------------------------------------------------------
diff --git a/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/GroovyDocToolTest.java b/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/GroovyDocToolTest.java
index 321f32f..fc62e4a 100644
--- a/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/GroovyDocToolTest.java
+++ b/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/GroovyDocToolTest.java
@@ -61,7 +61,7 @@ public class GroovyDocToolTest extends GroovyTestCase {
xmlToolForTests = new GroovyDocTool(
new FileSystemResourceManager("src"), // template storage
- new String[] {"src/test/groovy", "../../src/test"}, // source file dirs
+ new String[] {"src/test/groovy", "src/test/resources", "../../src/test"}, // source file dirs
new String[]{TEMPLATES_DIR + "/topLevel/rootDocStructuredData.xml"},
new String[]{TEMPLATES_DIR + "/packageLevel/packageDocStructuredData.xml"},
new String[]{TEMPLATES_DIR + "/classLevel/classDocStructuredData.xml"},
@@ -318,9 +318,9 @@ public class GroovyDocToolTest extends GroovyTestCase {
List<String> srcList = new ArrayList<String>();
String base = "org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond";
srcList.add(base + ".java");
- xmlTool.add(srcList);
+ xmlToolForTests.add(srcList);
MockOutputTool output = new MockOutputTool();
- xmlTool.renderToOutput(output, MOCK_DIR);
+ xmlToolForTests.renderToOutput(output, MOCK_DIR);
String doc = output.getText(MOCK_DIR + "/" + base + ".html");
assertNotNull("No GroovyDoc found for " + base, doc);
assertTrue("stringList not found in: \"" + doc + "\"", doc.contains("stringList"));
http://git-wip-us.apache.org/repos/asf/groovy/blob/8cfd70f8/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java
----------------------------------------------------------------------
diff --git a/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java b/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java
deleted file mode 100644
index 832543e..0000000
--- a/subprojects/groovy-groovydoc/src/test/groovy/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * 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.
- */
-package org.codehaus.groovy.tools.groovydoc.testfiles;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public abstract class JavaClassWithDiamond {
- public List<String> stringList = new ArrayList<>();
-}
http://git-wip-us.apache.org/repos/asf/groovy/blob/8cfd70f8/subprojects/groovy-groovydoc/src/test/resources/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java
----------------------------------------------------------------------
diff --git a/subprojects/groovy-groovydoc/src/test/resources/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java b/subprojects/groovy-groovydoc/src/test/resources/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java
new file mode 100644
index 0000000..832543e
--- /dev/null
+++ b/subprojects/groovy-groovydoc/src/test/resources/org/codehaus/groovy/tools/groovydoc/testfiles/JavaClassWithDiamond.java
@@ -0,0 +1,26 @@
+/*
+ * 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.
+ */
+package org.codehaus.groovy.tools.groovydoc.testfiles;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public abstract class JavaClassWithDiamond {
+ public List<String> stringList = new ArrayList<>();
+}