~ubuntu-branches/ubuntu/utopic/maven-enforcer/utopic

« back to all changes in this revision

Viewing changes to enforcer-rules/src/test/java/org/apache/maven/plugins/enforcer/TestNoSnapshots.java

  • Committer: Package Import Robot
  • Author(s): Torsten Werner
  • Date: 2011-09-12 22:30:16 UTC
  • mto: This revision was merged to the branch mainline in revision 3.
  • Revision ID: package-import@ubuntu.com-20110912223016-hrf239vjs4g4pik3
Tags: upstream-1.0
ImportĀ upstreamĀ versionĀ 1.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
package org.apache.maven.plugins.enforcer;
 
2
 
1
3
/*
2
4
 * Licensed to the Apache Software Foundation (ASF) under one
3
5
 * or more contributor license agreements.  See the NOTICE file
16
18
 * specific language governing permissions and limitations
17
19
 * under the License.
18
20
 */
19
 
package org.apache.maven.plugins.enforcer;
20
21
 
21
22
import java.io.IOException;
22
23
 
28
29
 
29
30
/**
30
31
 * The Class TestNoSnapshots.
31
 
 * 
 
32
 *
32
33
 * @author <a href="mailto:brianf@apache.org">Brian Fox</a>
33
34
 */
34
35
public class TestNoSnapshots
37
38
 
38
39
    /**
39
40
     * Test rule.
40
 
     * 
 
41
     *
41
42
     * @throws IOException Signals that an I/O exception has occurred.
42
43
     */
43
44
    public void testRule()
44
45
        throws IOException
45
46
    {
46
 
        
 
47
 
47
48
        ArtifactStubFactory factory = new ArtifactStubFactory();
48
49
        MockProject project = new MockProject();
49
50
        EnforcerRuleHelper helper = EnforcerTestUtils.getHelper( project );
59
60
        TestEnforcerRuleUtils.execute( rule, helper, true );
60
61
 
61
62
        project.setArtifact( factory.getSnapshotArtifact() );
62
 
        
 
63
 
63
64
        TestEnforcerRuleUtils.execute( rule, helper, true );
64
 
    } 
 
65
    }
65
66
 
66
67
    /**
67
68
     * Test id.