1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
package org.kuali.student.datadictionary.mojo; |
17 |
|
|
18 |
|
import java.io.File; |
19 |
|
import java.util.ArrayList; |
20 |
|
import java.util.List; |
21 |
|
import org.junit.After; |
22 |
|
import org.junit.AfterClass; |
23 |
|
import org.junit.Before; |
24 |
|
import org.junit.BeforeClass; |
25 |
|
import org.junit.Test; |
26 |
|
import static org.junit.Assert.*; |
27 |
|
|
28 |
|
|
29 |
|
@author |
30 |
|
|
|
|
| 0% |
Uncovered Elements: 24 (24) |
Complexity: 6 |
Complexity Density: 0.33 |
|
31 |
|
public class KSDictionaryDocMojoTest { |
32 |
|
private static final String DICTIONARY_DOC_DIRECTORY = "target/site/dictionary"; |
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
33 |
0
|
public KSDictionaryDocMojoTest() {... |
34 |
|
} |
35 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
36 |
0
|
@BeforeClass... |
37 |
|
public static void setUpClass() throws Exception { |
38 |
|
} |
39 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
40 |
0
|
@AfterClass... |
41 |
|
public static void tearDownClass() throws Exception { |
42 |
|
} |
43 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
44 |
0
|
@Before... |
45 |
|
public void setUp() { |
46 |
|
} |
47 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
48 |
0
|
@After... |
49 |
|
public void tearDown() { |
50 |
|
} |
51 |
|
|
52 |
|
|
53 |
|
|
54 |
|
|
|
|
| 0% |
Uncovered Elements: 18 (18) |
Complexity: 1 |
Complexity Density: 0.06 |
4
-
|
|
55 |
0
|
@Test... |
56 |
|
public void testExecute() throws Exception { |
57 |
0
|
System.out.println("execute"); |
58 |
0
|
KSDictionaryDocMojo instance = new KSDictionaryDocMojo(); |
59 |
0
|
List<String> supportFiles = new ArrayList (); |
60 |
|
|
61 |
0
|
supportFiles.add("ks-base-dictionary.xml"); |
62 |
0
|
supportFiles.add("ks-base-dictionary-validchars.xml"); |
63 |
0
|
supportFiles.add("org/kuali/rice/krad/bo/datadictionary/DataDictionaryBaseTypes.xml"); |
64 |
0
|
supportFiles.add("org/kuali/rice/krad/uif/UifControlDefinitions.xml"); |
65 |
0
|
supportFiles.add("org/kuali/rice/krad/uif/UifWidgetDefinitions.xml"); |
66 |
0
|
supportFiles.add("org/kuali/rice/krad/uif/UifFieldDefinitions.xml"); |
67 |
0
|
supportFiles.add("org/kuali/rice/krad/uif/UifGroupDefinitions.xml"); |
68 |
0
|
instance.setSupportFiles(supportFiles); |
69 |
0
|
List<String> inputFiles = new ArrayList (); |
70 |
0
|
inputFiles.add("ks-AtpInfo-dictionary.xml"); |
71 |
|
|
72 |
0
|
instance.setInputFiles(inputFiles); |
73 |
0
|
instance.setHtmlDirectory(new File (DICTIONARY_DOC_DIRECTORY)); |
74 |
0
|
instance.execute(); |
75 |
0
|
assertTrue(new File(instance.getHtmlDirectory() + "/" + "index.html").exists()); |
76 |
0
|
assertTrue(new File(instance.getHtmlDirectory() + "/" + "AtpInfo.html").exists()); |
77 |
|
} |
78 |
|
} |