summaryrefslogtreecommitdiffstats
path: root/ajdoc/testsrc
diff options
context:
space:
mode:
authoraclement <aclement>2008-03-20 00:12:46 +0000
committeraclement <aclement>2008-03-20 00:12:46 +0000
commitd4d6cf4b6d2ee80c9ec23d36ee2f1158737bb6ab (patch)
treea42cd1e0e280e1ee3dea5cb8f2295b8d3822d11d /ajdoc/testsrc
parent331316fef7cc6c6ba77fd0ed63aaed630acaae28 (diff)
downloadaspectj-d4d6cf4b6d2ee80c9ec23d36ee2f1158737bb6ab.tar.gz
aspectj-d4d6cf4b6d2ee80c9ec23d36ee2f1158737bb6ab.zip
164356: test and fix: ajdoc
Diffstat (limited to 'ajdoc/testsrc')
-rw-r--r--ajdoc/testsrc/org/aspectj/tools/ajdoc/BugTests.java26
1 files changed, 26 insertions, 0 deletions
diff --git a/ajdoc/testsrc/org/aspectj/tools/ajdoc/BugTests.java b/ajdoc/testsrc/org/aspectj/tools/ajdoc/BugTests.java
index eeb8f141a..4db3c19f5 100644
--- a/ajdoc/testsrc/org/aspectj/tools/ajdoc/BugTests.java
+++ b/ajdoc/testsrc/org/aspectj/tools/ajdoc/BugTests.java
@@ -130,4 +130,30 @@ public class BugTests extends AjdocTestCase {
assertTrue("expected build of project to abort",Main.hasAborted());
}
+ /**
+ * javadoc comments should still appear even if preceded by
+ * 'normal' comments
+ */
+ public void testPr164356() throws Exception {
+ initialiseProject("pr164356");
+ File[] files = {new File(getAbsoluteProjectDir() + "/C.java")};
+ runAjdoc(files);
+ File htmlFile = new File(getAbsolutePathOutdir() + "/C.html");
+ if (htmlFile == null || !htmlFile.exists()) {
+ fail("couldn't find " + htmlFile.getAbsolutePath() +
+ " (ajc aborted: " + Main.hasAborted() + ")");
+ }
+ String foo = "description of foo";
+ String bar = "description of bar";
+ String goo = "description of goo";
+ assertTrue("expected method description 'description of foo' to appear" +
+ " in ajdoc output but it did not",
+ AjdocOutputChecker.containsString(htmlFile, foo));
+ assertTrue("expected method description 'description of bar' to " +
+ "appear in ajdoc output but it did not",
+ AjdocOutputChecker.containsString(htmlFile, bar));
+ assertFalse("didn't expect method description 'description of goo' to " +
+ "appear in ajdoc output but it did not",
+ AjdocOutputChecker.containsString(htmlFile, goo));
+ }
}