View Javadoc
1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one
3    * or more contributor license agreements.  See the NOTICE file
4    * distributed with this work for additional information
5    * regarding copyright ownership.  The ASF licenses this file
6    * to you under the Apache License, Version 2.0 (the
7    * "License"); you may not use this file except in compliance
8    * with the License.  You may obtain a copy of the License at
9    *
10   *   http://www.apache.org/licenses/LICENSE-2.0
11   *
12   * Unless required by applicable law or agreed to in writing,
13   * software distributed under the License is distributed on an
14   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15   * KIND, either express or implied.  See the License for the
16   * specific language governing permissions and limitations
17   * under the License.
18   */
19  package org.apache.maven.plugin.eclipse.it;
20  
21  import java.util.Properties;
22  
23  /**
24   * Unit Tests for MyEclipse plugin
25   * 
26   * @author <a href="mailto:olivier.jacob@gmail.com">Olivier Jacob</a>
27   */
28  public class MyEclipsePluginIT
29      extends AbstractEclipsePluginIT
30  {
31      /**
32       * Web project, no spring/struts/hibernate capability, J2EE 1.3
33       * 
34       * @throws Exception
35       */
36      public void testProject01()
37          throws Exception
38      {
39          doMyEclipseProjectTest( "project-myeclipse-01" );
40      }
41  
42      /**
43       * Web project, no spring/struts/hibernate capability, J2EE 1.4
44       * 
45       * @throws Exception
46       */
47      public void testProject02()
48          throws Exception
49      {
50          doMyEclipseProjectTest( "project-myeclipse-02" );
51      }
52  
53      /**
54       * Simple project with Spring capability
55       * 
56       * @throws Exception
57       */
58      public void testProject03()
59          throws Exception
60      {
61          doMyEclipseProjectTest( "project-myeclipse-03" );
62      }
63  
64      /**
65       * Simple project with Spring and Hibernate capabilities
66       * 
67       * @throws Exception
68       */
69      public void testProject04()
70          throws Exception
71      {
72          doMyEclipseProjectTest( "project-myeclipse-04" );
73      }
74  
75      /**
76       * Simple project with additionalConfig
77       * 
78       * @throws Exception
79       */
80      public void xxignorexxCerificateProblemtestProject05()
81          throws Exception
82      {
83          doMyEclipseProjectTest( "project-myeclipse-05" );
84      }
85  
86      /**
87       * Simple project with with spring configuration that points at non-existent directory
88       * 
89       * @throws Exception
90       */
91      public void testMyEclipseProject06MECLIPSE427()
92          throws Exception
93      {
94          doMyEclipseProjectTest( "project-myeclipse-06-MECLIPSE-427" );
95      }
96  
97      /**
98       * Verifies spring files created with sub-projects (modules) module-1 should have spring bean files in the
99       * .springBeans file. module-2 should not have spring bean files in the .springBeans file.
100      * 
101      * @throws Exception
102      */
103     public void testProject07MECLIPSE445()
104         throws Exception
105     {
106         doMyEclipseProjectTest( "project-myeclipse-07-MECLIPSE-445" );
107     }
108 
109     private void doMyEclipseProjectTest( String project )
110         throws Exception
111     {
112         testProject( project, new Properties(), "myeclipse-clean", "myeclipse" );
113     }
114 
115 }