1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.maven.plugin.jxr;
20
21 import java.io.File;
22
23
24
25
26 public class JxrTestReportTest extends AbstractJxrTestCase {
27
28
29
30
31
32 public void testSourceDir() throws Exception {
33 generateReport("test-jxr", "testsourcedir-test/testsourcedir-test-plugin-config.xml");
34
35 File xrefTestDir = new File(getBasedir(), "target/test/unit/testsourcedir-test/target/site/xref-test");
36
37
38 assertTrue(new File(xrefTestDir, "testsourcedir/test/AppSampleTest.html").exists());
39 assertTrue(new File(xrefTestDir, "testsourcedir/test/AppTest.html").exists());
40 assertTrue(new File(xrefTestDir, "testsourcedir/test/package-frame.html").exists());
41 assertTrue(new File(xrefTestDir, "testsourcedir/test/package-summary.html").exists());
42 assertTrue(new File(xrefTestDir, "allclasses-frame.html").exists());
43 assertTrue(new File(xrefTestDir, "index.html").exists());
44 assertTrue(new File(xrefTestDir, "overview-frame.html").exists());
45 assertTrue(new File(xrefTestDir, "overview-summary.html").exists());
46 assertTrue(new File(xrefTestDir, "stylesheet.css").exists());
47
48
49 String str = readFile(xrefTestDir, "testsourcedir/test/AppSampleTest.html");
50 assertFalse(str.toLowerCase().contains("/apidocs/testsourcedir/test/AppSample.html\"".toLowerCase()));
51
52 str = readFile(xrefTestDir, "testsourcedir/test/AppTest.html");
53 assertFalse(str.toLowerCase().contains("/apidocs/testsourcedir/test/App.html\"".toLowerCase()));
54 }
55 }