You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by el...@apache.org on 2020/07/06 11:44:30 UTC

[maven-dependency-plugin] branch 21compat created (now 387a4d9)

This is an automated email from the ASF dual-hosted git repository.

elharo pushed a change to branch 21compat
in repository https://gitbox.apache.org/repos/asf/maven-dependency-plugin.git.


      at 387a4d9  simple test that looks up a mojo

This branch includes the following new commits:

     new 387a4d9  simple test that looks up a mojo

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[maven-dependency-plugin] 01/01: simple test that looks up a mojo

Posted by el...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

elharo pushed a commit to branch 21compat
in repository https://gitbox.apache.org/repos/asf/maven-dependency-plugin.git

commit 387a4d9a1c34a91244ae169c9ff5bda927bc0ad4
Author: Elliotte Rusty Harold <el...@ibiblio.org>
AuthorDate: Mon Jul 6 07:44:10 2020 -0400

    simple test that looks up a mojo
---
 .../maven/plugins/dependency/TestLookupMojo.java   | 50 ++++++++++++++++++++++
 1 file changed, 50 insertions(+)

diff --git a/src/test/java/org/apache/maven/plugins/dependency/TestLookupMojo.java b/src/test/java/org/apache/maven/plugins/dependency/TestLookupMojo.java
new file mode 100644
index 0000000..58247b4
--- /dev/null
+++ b/src/test/java/org/apache/maven/plugins/dependency/TestLookupMojo.java
@@ -0,0 +1,50 @@
+package org.apache.maven.plugins.dependency;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+
+/**
+ * A minimal test case to debug Mojo lookups in 3.1.0.
+ */
+public class TestLookupMojo
+    extends AbstractDependencyMojoTestCase
+{
+    GetMojo mojo;
+
+    protected void setUp()
+        throws Exception
+    {
+        // required for mojo lookups to work
+        super.setUp( "markers", false );
+
+        File testPom = new File( getBasedir(), "target/test-classes/unit/get-test/plugin-config.xml" );
+        mojo = (GetMojo) lookupMojo( "get", testPom );
+
+        assertNotNull( mojo );
+    }
+
+    public void testSomething()
+        throws Exception
+    {
+        assertEquals(1, 1);
+    }
+
+}