diff --git a/allure-awaitility/build.gradle.kts b/allure-awaitility/build.gradle.kts index 587ca0308..e7afac938 100644 --- a/allure-awaitility/build.gradle.kts +++ b/allure-awaitility/build.gradle.kts @@ -7,9 +7,10 @@ val awaitilityVersion = "4.2.1" dependencies { agent("org.aspectj:aspectjweaver") api(project(":allure-java-commons")) - implementation("org.awaitility:awaitility:$awaitilityVersion") + compileOnly("org.awaitility:awaitility:$awaitilityVersion") testImplementation("javax.annotation:javax.annotation-api") testImplementation("org.assertj:assertj-core") + testImplementation("org.awaitility:awaitility:$awaitilityVersion") testImplementation("org.junit.jupiter:junit-jupiter-api") testImplementation("org.slf4j:slf4j-simple") testImplementation(project(":allure-java-commons-test")) @@ -27,4 +28,4 @@ tasks.jar { tasks.test { useJUnitPlatform() -} \ No newline at end of file +} diff --git a/allure-cucumber4-jvm/build.gradle.kts b/allure-cucumber4-jvm/build.gradle.kts index 37b660454..26b244ee0 100644 --- a/allure-cucumber4-jvm/build.gradle.kts +++ b/allure-cucumber4-jvm/build.gradle.kts @@ -4,9 +4,11 @@ val cucumberVersion = "4.8.0" dependencies { api(project(":allure-java-commons")) - implementation("io.cucumber:cucumber-core:$cucumberVersion") - implementation("io.cucumber:cucumber-java:$cucumberVersion") + compileOnly("io.cucumber:cucumber-core:$cucumberVersion") + compileOnly("io.cucumber:cucumber-java:$cucumberVersion") testImplementation("commons-io:commons-io") + testImplementation("io.cucumber:cucumber-core:$cucumberVersion") + testImplementation("io.cucumber:cucumber-java:$cucumberVersion") testImplementation("io.github.glytching:junit-extensions") testImplementation("org.assertj:assertj-core") testImplementation("org.junit.jupiter:junit-jupiter-api") diff --git a/allure-cucumber5-jvm/build.gradle.kts b/allure-cucumber5-jvm/build.gradle.kts index 0bb513d73..4e0d44c9d 100644 --- a/allure-cucumber5-jvm/build.gradle.kts +++ b/allure-cucumber5-jvm/build.gradle.kts @@ -6,11 +6,11 @@ val cucumberGherkinVersion = "5.1.0" dependencies { api(project(":allure-java-commons")) compileOnly("io.cucumber:cucumber-plugin:$cucumberVersion") - implementation("io.cucumber:gherkin:$cucumberGherkinVersion") - testImplementation("io.cucumber:gherkin:$cucumberGherkinVersion") + compileOnly("io.cucumber:gherkin:$cucumberGherkinVersion") + testImplementation("commons-io:commons-io") testImplementation("io.cucumber:cucumber-core:$cucumberVersion") testImplementation("io.cucumber:cucumber-java:$cucumberVersion") - testImplementation("commons-io:commons-io") + testImplementation("io.cucumber:gherkin:$cucumberGherkinVersion") testImplementation("io.github.glytching:junit-extensions") testImplementation("org.assertj:assertj-core") testImplementation("org.junit.jupiter:junit-jupiter-api") diff --git a/allure-cucumber6-jvm/build.gradle.kts b/allure-cucumber6-jvm/build.gradle.kts index e0a1922ab..cbe2c710c 100644 --- a/allure-cucumber6-jvm/build.gradle.kts +++ b/allure-cucumber6-jvm/build.gradle.kts @@ -6,7 +6,7 @@ val cucumberGherkinVersion = "18.0.0" dependencies { api(project(":allure-java-commons")) compileOnly("io.cucumber:cucumber-plugin:$cucumberVersion") - implementation("io.cucumber:gherkin:$cucumberGherkinVersion") + compileOnly("io.cucumber:gherkin:$cucumberGherkinVersion") testImplementation("commons-io:commons-io") testImplementation("io.cucumber:cucumber-core:$cucumberVersion") testImplementation("io.cucumber:cucumber-java:$cucumberVersion") diff --git a/allure-cucumber7-jvm/build.gradle.kts b/allure-cucumber7-jvm/build.gradle.kts index 4b33f0eaf..2a1f44c98 100644 --- a/allure-cucumber7-jvm/build.gradle.kts +++ b/allure-cucumber7-jvm/build.gradle.kts @@ -6,7 +6,7 @@ val cucumberGherkinVersion = "26.2.0" dependencies { api(project(":allure-java-commons")) compileOnly("io.cucumber:cucumber-plugin:$cucumberVersion") - implementation("io.cucumber:gherkin:$cucumberGherkinVersion") + compileOnly("io.cucumber:gherkin:$cucumberGherkinVersion") testImplementation("commons-io:commons-io") testImplementation("io.cucumber:cucumber-core:$cucumberVersion") testImplementation("io.cucumber:cucumber-java:$cucumberVersion") diff --git a/allure-grpc/build.gradle.kts b/allure-grpc/build.gradle.kts index cd1ddfd34..54ed3b5da 100644 --- a/allure-grpc/build.gradle.kts +++ b/allure-grpc/build.gradle.kts @@ -14,16 +14,17 @@ val protobufVersion = "4.27.2" dependencies { agent("org.aspectj:aspectjweaver") api(project(":allure-attachments")) - implementation("io.grpc:grpc-core:$grpcVersion") - implementation("com.google.protobuf:protobuf-java-util:$protobufVersion") - - testImplementation("io.grpc:grpc-stub:$grpcVersion") - testImplementation("io.grpc:grpc-protobuf:$grpcVersion") - testImplementation("io.grpc:grpc-netty-shaded:$grpcVersion") + compileOnly("com.google.protobuf:protobuf-java-util:$protobufVersion") + compileOnly("io.grpc:grpc-core:$grpcVersion") + testImplementation("com.google.protobuf:protobuf-java-util:$protobufVersion") testImplementation("com.google.protobuf:protobuf-java:$protobufVersion") - testImplementation("org.grpcmock:grpcmock-junit5") + testImplementation("io.grpc:grpc-core:$grpcVersion") + testImplementation("io.grpc:grpc-netty-shaded:$grpcVersion") + testImplementation("io.grpc:grpc-protobuf:$grpcVersion") + testImplementation("io.grpc:grpc-stub:$grpcVersion") testImplementation("javax.annotation:javax.annotation-api") testImplementation("org.assertj:assertj-core") + testImplementation("org.grpcmock:grpcmock-junit5") testImplementation("org.junit.jupiter:junit-jupiter-api") testImplementation("org.slf4j:slf4j-simple") testImplementation(project(":allure-java-commons-test")) diff --git a/allure-hamcrest/build.gradle.kts b/allure-hamcrest/build.gradle.kts index 8ccb0ee47..6b0e5dd3a 100644 --- a/allure-hamcrest/build.gradle.kts +++ b/allure-hamcrest/build.gradle.kts @@ -3,11 +3,12 @@ description = "Allure Hamcrest Assertions Integration" dependencies { api(project(":allure-java-commons")) compileOnly("org.aspectj:aspectjrt") - implementation("org.hamcrest:hamcrest") + compileOnly("org.hamcrest:hamcrest") testAnnotationProcessor(project(":allure-descriptions-javadoc")) + testImplementation("org.assertj:assertj-core") + testImplementation("org.hamcrest:hamcrest") testImplementation("org.junit.jupiter:junit-jupiter-api") testImplementation("org.junit.jupiter:junit-jupiter-params") - testImplementation("org.assertj:assertj-core") testImplementation("org.slf4j:slf4j-simple") testImplementation(project(":allure-java-commons-test")) testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine") diff --git a/allure-httpclient/build.gradle.kts b/allure-httpclient/build.gradle.kts index 087e00bfb..9f3b4c554 100644 --- a/allure-httpclient/build.gradle.kts +++ b/allure-httpclient/build.gradle.kts @@ -1,10 +1,13 @@ description = "Allure Apache HttpClient Integration" +val httpClient4Version = "4.5.14"; + dependencies { api(project(":allure-attachments")) - implementation("org.apache.httpcomponents:httpclient") + compileOnly("org.apache.httpcomponents:httpclient:$httpClient4Version") testImplementation("com.github.tomakehurst:wiremock") testImplementation("io.github.glytching:junit-extensions") + testImplementation("org.apache.httpcomponents:httpclient:$httpClient4Version") testImplementation("org.assertj:assertj-core") testImplementation("org.junit.jupiter:junit-jupiter-api") testImplementation("org.mockito:mockito-core") diff --git a/allure-httpclient5/build.gradle.kts b/allure-httpclient5/build.gradle.kts index eb42ad2da..aa6d53179 100644 --- a/allure-httpclient5/build.gradle.kts +++ b/allure-httpclient5/build.gradle.kts @@ -1,10 +1,13 @@ description = "Allure Apache HttpClient5 Integration" +val httpClient5Version = "5.3.1"; + dependencies { api(project(":allure-attachments")) - implementation("org.apache.httpcomponents.client5:httpclient5") + compileOnly("org.apache.httpcomponents.client5:httpclient5:$httpClient5Version") testImplementation("com.github.tomakehurst:wiremock") testImplementation("io.github.glytching:junit-extensions") + testImplementation("org.apache.httpcomponents.client5:httpclient5:$httpClient5Version") testImplementation("org.assertj:assertj-core") testImplementation("org.junit.jupiter:junit-jupiter-api") testImplementation("org.mockito:mockito-core") @@ -24,4 +27,4 @@ tasks.jar { tasks.test { useJUnitPlatform() -} \ No newline at end of file +} diff --git a/allure-java-migration/build.gradle.kts b/allure-java-migration/build.gradle.kts deleted file mode 100644 index f6a0f755e..000000000 --- a/allure-java-migration/build.gradle.kts +++ /dev/null @@ -1,35 +0,0 @@ -description = "Allure Java Migration Utils" - -val junitVersion = "4.13.2" -val testNgVersion = "6.14.3" - -dependencies { - api("org.apache.commons:commons-lang3") - api("org.aspectj:aspectjrt") - api(project(":allure-java-commons")) - implementation("junit:junit:$junitVersion") - implementation("org.testng:testng:$testNgVersion") - testImplementation("io.github.glytching:junit-extensions") - testImplementation("junit:junit:$junitVersion") - testImplementation("org.assertj:assertj-core") - testImplementation("org.junit.jupiter:junit-jupiter-api") - testImplementation("org.junit.jupiter:junit-jupiter-params") - testImplementation("org.mockito:mockito-core") - testImplementation("org.slf4j:slf4j-simple") - testImplementation("org.testng:testng:$testNgVersion") - testImplementation(project(":allure-java-commons-test")) - testImplementation(project(":allure-junit-platform")) - testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine") -} - -tasks.jar { - manifest { - attributes(mapOf( - "Automatic-Module-Name" to "io.qameta.allure.migration" - )) - } -} - -tasks.test { - useJUnitPlatform() -} diff --git a/allure-java-migration/src/main/java/io/qameta/allure/aspects/Allure1Annotations.java b/allure-java-migration/src/main/java/io/qameta/allure/aspects/Allure1Annotations.java deleted file mode 100644 index 1232ea19a..000000000 --- a/allure-java-migration/src/main/java/io/qameta/allure/aspects/Allure1Annotations.java +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Copyright 2016-2024 Qameta Software Inc - * - * Licensed 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. - */ -package io.qameta.allure.aspects; - -import io.qameta.allure.model.Label; -import io.qameta.allure.model.Link; -import io.qameta.allure.model.Parameter; -import io.qameta.allure.model.TestResult; -import org.aspectj.lang.reflect.MethodSignature; -import ru.yandex.qatools.allure.annotations.Description; -import ru.yandex.qatools.allure.annotations.Features; -import ru.yandex.qatools.allure.annotations.Issue; -import ru.yandex.qatools.allure.annotations.Issues; -import ru.yandex.qatools.allure.annotations.Severity; -import ru.yandex.qatools.allure.annotations.Stories; -import ru.yandex.qatools.allure.annotations.TestCaseId; -import ru.yandex.qatools.allure.annotations.Title; -import ru.yandex.qatools.allure.model.DescriptionType; - -import java.lang.reflect.Method; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; -import java.util.stream.Collectors; -import java.util.stream.IntStream; - -import static io.qameta.allure.util.ResultsUtils.createParameter; - -/** - * Allure labels utils. - */ -final class Allure1Annotations { - - private static final String SUITE_LABEL = "suite"; - - private final MethodSignature signature; - - private final Object[] args; - - Allure1Annotations(final MethodSignature signature, final Object... args) { - this.args = Arrays.copyOf(args, args.length); - this.signature = signature; - } - - public void updateTitle(final TestResult result) { - final Method method = getMethod(); - if (method.isAnnotationPresent(Title.class)) { - final Title title = method.getAnnotation(Title.class); - result.setName(title.value()); - } - final Class type = getType(); - if (type.isAnnotationPresent(Title.class)) { - final Title title = type.getAnnotation(Title.class); - final List