diff --git a/pom.xml b/pom.xml index b946481..3ae08b0 100644 --- a/pom.xml +++ b/pom.xml @@ -31,7 +31,6 @@ - 5.12.1 0.9.0.M4 2025-04-05T17:02:05Z @@ -61,7 +60,7 @@ com.google.inject guice - 6.0.0 + 5.1.0 @@ -69,14 +68,6 @@ jsr305 3.0.2 - - jakarta.annotation - jakarta.annotation-api - 2.1.1 - provided - true - - org.junit.jupiter junit-jupiter-api diff --git a/src/test/java/org/codehaus/plexus/testing/PlexusTestJakartaTest.java b/src/test/java/org/codehaus/plexus/testing/PlexusTestJakartaTest.java deleted file mode 100644 index 72e39da..0000000 --- a/src/test/java/org/codehaus/plexus/testing/PlexusTestJakartaTest.java +++ /dev/null @@ -1,46 +0,0 @@ -package org.codehaus.plexus.testing; - -/* - * 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 jakarta.inject.Inject; -import org.junit.jupiter.api.Test; - -import static org.junit.jupiter.api.Assertions.assertNotNull; -import static org.junit.jupiter.api.Assertions.assertNull; - -@PlexusTest -class PlexusTestJakartaTest { - - @Inject - private TestJakartaComponent testJakartaComponent; - - @Test - void dependencyShouldBeInjected() { - assertNotNull(testJakartaComponent); - assertNotNull(testJakartaComponent.getTestJakartaComponent2()); - // assertNotNull(testJakartaComponent.getTestJakartaComponent3Named()); - assertNull(testJakartaComponent.getTestJakartaComponent3NullableJavax()); - assertNull(testJakartaComponent.getTestJakartaComponent3NullableJakarta()); - - assertNotNull(testJakartaComponent.getTestJavaxComponent2()); - assertNotNull(testJakartaComponent.getTestJavaxComponent2()); - assertNotNull(testJakartaComponent.getTestJavaxComponent2()); - } -} diff --git a/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent.java b/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent.java deleted file mode 100644 index c4912a5..0000000 --- a/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent.java +++ /dev/null @@ -1,67 +0,0 @@ -package org.codehaus.plexus.testing; - -/* - * 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 jakarta.inject.Inject; -import jakarta.inject.Named; - -@Named -public class TestJakartaComponent { - @Inject - private TestJavaxComponent2 testJavaxComponent2; - - @Inject - private TestJakartaComponent2 testJakartaComponent2; - - // @Inject - // @Nonnull - // @Named("someComponent") - // private TestJakartaComponent3 testJakartaComponent3Named; - - @Inject - @javax.annotation.Nullable - @Named("someComponentNotExisting") - private TestJakartaComponent3 testJakartaComponent3NullableJavax; - - @Inject - @jakarta.annotation.Nullable - @Named("someComponentNotExisting") - private TestJakartaComponent3 testJakartaComponent3NullableJakarta; - - public TestJavaxComponent2 getTestJavaxComponent2() { - return testJavaxComponent2; - } - - public TestJakartaComponent2 getTestJakartaComponent2() { - return testJakartaComponent2; - } - - // public TestJakartaComponent3 getTestJakartaComponent3Named() { - // return testJakartaComponent3Named; - // } - - public TestJakartaComponent3 getTestJakartaComponent3NullableJavax() { - return testJakartaComponent3NullableJavax; - } - - public TestJakartaComponent3 getTestJakartaComponent3NullableJakarta() { - return testJakartaComponent3NullableJakarta; - } -} diff --git a/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent2.java b/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent2.java deleted file mode 100644 index 7db989d..0000000 --- a/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent2.java +++ /dev/null @@ -1,25 +0,0 @@ -package org.codehaus.plexus.testing; - -/* - * 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 javax.inject.Named; - -@Named -public class TestJakartaComponent2 {} diff --git a/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent3.java b/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent3.java deleted file mode 100644 index cb0b286..0000000 --- a/src/test/java/org/codehaus/plexus/testing/TestJakartaComponent3.java +++ /dev/null @@ -1,25 +0,0 @@ -package org.codehaus.plexus.testing; - -/* - * 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 jakarta.inject.Named; - -@Named("someComponent") -public class TestJakartaComponent3 {}