KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > tools > ant > taskdefs > optional > DotnetTest


1 /*
2  * Copyright 2002-2004 The Apache Software Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */

17 package org.apache.tools.ant.taskdefs.optional;
18
19 import java.io.*;
20 import java.util.Properties JavaDoc;
21
22 import org.apache.tools.ant.BuildFileTest;
23
24 /**
25  * Tests the Dotnet tasks, based off WsdlToDotnetTest
26  *
27  * @since Ant 1.6
28  */

29 public class DotnetTest extends BuildFileTest {
30
31     /**
32      * Description of the Field
33      */

34     private final static String JavaDoc TASKDEFS_DIR = "src/etc/testcases/taskdefs/optional/";
35
36
37     /**
38      * Constructor
39      *
40      * @param name testname
41      */

42     public DotnetTest(String JavaDoc name) {
43         super(name);
44     }
45
46
47     /**
48      * The JUnit setup method
49      */

50     public void setUp() {
51         configureProject(TASKDEFS_DIR + "dotnet.xml");
52     }
53
54
55     /**
56      * The teardown method for JUnit
57      */

58     public void tearDown() {
59         executeTarget("teardown");
60     }
61
62
63     /**
64      * A unit test for JUnit
65      */

66     public void testCSC() throws Exception JavaDoc {
67         executeTarget("testCSC");
68     }
69
70
71     /**
72      * A unit test for JUnit
73      */

74     public void testCSCintrinsicFileset() throws Exception JavaDoc {
75         executeTarget("testCSCintrinsicFileset");
76     }
77
78
79     /**
80      * A unit test for JUnit
81      */

82     public void testCSCdll() throws Exception JavaDoc {
83         executeTarget("testCSCdll");
84     }
85
86     /**
87      * A unit test for JUnit
88      */

89     public void testCscReferences() throws Exception JavaDoc {
90         executeTarget("testCscReferences");
91     }
92
93     /**
94      * test we can assemble
95      */

96     public void testILASM() throws Exception JavaDoc {
97         executeTarget("testILASM");
98     }
99
100     /**
101      * test we can disassemble
102      */

103     public void testILDASM() throws Exception JavaDoc {
104         executeTarget("testILDASM");
105     }
106
107     /**
108      * test we can disassemble
109      */

110     public void testILDASM_empty() throws Exception JavaDoc {
111         expectBuildExceptionContaining("testILDASM_empty",
112                 "parameter validation",
113                 "invalid");
114     }
115
116     /**
117      * test we can handle jsharp (if found)
118      */

119     public void testJsharp() throws Exception JavaDoc {
120         executeTarget("jsharp");
121     }
122
123     /**
124      * test we can handle jsharp (if found)
125      */

126     public void testResponseFile() throws Exception JavaDoc {
127         executeTarget("testCSCresponseFile");
128     }
129
130 }
131
132
Popular Tags