Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ jobs:
java-version: '11'

- name: Build with Gradle
timeout-minutes: 15
run: ./gradlew build

- name: Codecov upload
Expand Down
33 changes: 33 additions & 0 deletions .github/workflows/maven-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Copyright 2025 EPAM Systems
# 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.

name: Publish to Maven Central

on:
workflow_dispatch:
inputs:
version:
description: 'Release version (e.g., 5.3.14)'
required: true
type: string

jobs:
publish:
uses: reportportal/.github/.github/workflows/maven-publish.yml@main
with:
version: ${{ github.event.inputs.version }}
artifact: agent-java-cucumber6
package_suffixes: '-javadoc.jar,-javadoc.jar.asc,-javadoc.jar.md5,-javadoc.jar.sha1,-javadoc.jar.sha256,-javadoc.jar.sha512,-sources.jar,-sources.jar.asc,-sources.jar.md5,-sources.jar.sha1,-sources.jar.sha256,-sources.jar.sha512,.jar,.jar.asc,.jar.md5,.jar.sha1,.jar.sha256,.jar.sha512,.pom,.pom.asc,.pom.md5,.pom.sha1,.pom.sha256,.pom.sha512,.module,.module.asc,.module.md5,.module.sha1,.module.sha256,.module.sha512'
secrets:
SONATYPE_USER: ${{ secrets.SONATYPE_USER }}
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
112 changes: 0 additions & 112 deletions .github/workflows/promote.yml

This file was deleted.

2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Changelog
## [Unreleased]
### Changed
- Client version updated on [5.3.16](https://github.com/reportportal/client-java/releases/tag/5.3.16), by @HardNorth

## [5.4.2]
### Changed
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,14 @@ repositories {
}

dependencies {
api 'com.epam.reportportal:client-java:5.3.12'
api 'com.epam.reportportal:client-java:5.3.16'

implementation "io.cucumber:cucumber-gherkin:${project.cucumber_version}"
implementation 'org.slf4j:slf4j-api:2.0.7'

testImplementation 'com.squareup.okhttp3:okhttp:4.12.0'
testImplementation "io.cucumber:cucumber-java:${project.cucumber_version}"
testImplementation 'com.epam.reportportal:agent-java-test-utils:0.0.7'
testImplementation 'com.epam.reportportal:agent-java-test-utils:0.0.13'
testImplementation "io.cucumber:cucumber-testng:${project.cucumber_version}"
testImplementation 'org.aspectj:aspectjweaver:1.9.19'
testImplementation 'org.hamcrest:hamcrest-core:2.2'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ public static class SimpleTestScenarioReporterTest extends AbstractTestNGCucumbe
@BeforeEach
public void setup() {
TestUtils.mockLaunch(client, launchId, suiteId, testId, stepIds);
TestUtils.mockLogging(client);
TestScenarioReporter.RP.set(reportPortal);
TestStepReporter.RP.set(reportPortal);
}
Expand Down
12 changes: 6 additions & 6 deletions src/test/java/com/epam/reportportal/cucumber/BackgroundTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,14 @@ public class BackgroundTest {
@CucumberOptions(features = "src/test/resources/features/BackgroundScenario.feature", glue = {
"com.epam.reportportal.cucumber.integration.feature" }, plugin = { "pretty",
"com.epam.reportportal.cucumber.integration.TestStepReporter" })
public static class MyStepReporter extends AbstractTestNGCucumberTests {
public static class MyStepReporterTest extends AbstractTestNGCucumberTests {

}

@CucumberOptions(features = "src/test/resources/features/BackgroundScenario.feature", glue = {
"com.epam.reportportal.cucumber.integration.feature" }, plugin = { "pretty",
"com.epam.reportportal.cucumber.integration.TestScenarioReporter" })
public static class MyScenarioReporter extends AbstractTestNGCucumberTests {
public static class MyScenarioReporterTest extends AbstractTestNGCucumberTests {

}

Expand Down Expand Up @@ -107,15 +107,15 @@ public void tearDown() {
@Test
@SuppressWarnings("unchecked")
public void verify_background_step_reporter() {
runTests(MyStepReporter.class);
runTests(MyStepReporterTest.class);

verify(client, times(1)).startTestItem(any());
verify(client, times(2)).startTestItem(same(suiteId), any());
ArgumentCaptor<StartTestItemRQ> firstStepStarts = ArgumentCaptor.forClass(StartTestItemRQ.class);
verify(client, times(2)).startTestItem(same(testIds.get(0)), firstStepStarts.capture());
ArgumentCaptor<StartTestItemRQ> secondStepStarts = ArgumentCaptor.forClass(StartTestItemRQ.class);
verify(client, times(2)).startTestItem(same(testIds.get(1)), secondStepStarts.capture());
verify(client, times(4)).log(any(List.class));
verify(client, times(5)).log(any(List.class));

assertThat(firstStepStarts.getAllValues()
.stream()
Expand Down Expand Up @@ -147,7 +147,7 @@ public void verify_background_step_reporter() {
@SuppressWarnings("unchecked")
public void verify_background_scenario_reporter() {
mockNestedSteps(client, nestedSteps);
runTests(MyScenarioReporter.class);
runTests(MyScenarioReporterTest.class);

verify(client, times(1)).startTestItem(any());
verify(client, times(1)).startTestItem(same(suiteId), any());
Expand All @@ -156,7 +156,7 @@ public void verify_background_scenario_reporter() {
verify(client, times(2)).startTestItem(same(stepIds.get(0)), firstStepStarts.capture());
ArgumentCaptor<StartTestItemRQ> secondStepStarts = ArgumentCaptor.forClass(StartTestItemRQ.class);
verify(client, times(2)).startTestItem(same(stepIds.get(1)), secondStepStarts.capture());
verify(client, times(4)).log(any(List.class));
verify(client, times(5)).log(any(List.class));

assertThat(firstStepStarts.getAllValues()
.stream()
Expand Down
13 changes: 7 additions & 6 deletions src/test/java/com/epam/reportportal/cucumber/CodeRefTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,21 +52,21 @@ public class CodeRefTest {
@CucumberOptions(features = "src/test/resources/features/belly.feature", glue = {
"com.epam.reportportal.cucumber.integration.feature" }, plugin = { "pretty",
"com.epam.reportportal.cucumber.integration.TestScenarioReporter" })
public static class BellyScenarioReporter extends AbstractTestNGCucumberTests {
public static class BellyScenarioReporterTest extends AbstractTestNGCucumberTests {

}

@CucumberOptions(features = "src/test/resources/features/belly.feature", glue = {
"com.epam.reportportal.cucumber.integration.feature" }, plugin = { "pretty",
"com.epam.reportportal.cucumber.integration.TestStepReporter" })
public static class BellyStepReporter extends AbstractTestNGCucumberTests {
public static class BellyStepReporterTest extends AbstractTestNGCucumberTests {

}

@CucumberOptions(features = "src/test/resources/features/TwoScenarioInOne.feature", glue = {
"com.epam.reportportal.cucumber.integration.feature" }, plugin = { "pretty",
"com.epam.reportportal.cucumber.integration.TestStepReporter" })
public static class TwoFeaturesStepReporter extends AbstractTestNGCucumberTests {
public static class TwoFeaturesStepReporterTest extends AbstractTestNGCucumberTests {

}

Expand All @@ -85,6 +85,7 @@ public static class TwoFeaturesStepReporter extends AbstractTestNGCucumberTests
@BeforeEach
public void initLaunch() {
TestUtils.mockLaunch(client, launchId, suiteId, tests);
TestUtils.mockLogging(client);
TestScenarioReporter.RP.set(reportPortal);
TestStepReporter.RP.set(reportPortal);
}
Expand All @@ -95,7 +96,7 @@ public void initLaunch() {

@Test
public void verify_code_reference_scenario_reporter() {
TestUtils.runTests(BellyScenarioReporter.class);
TestUtils.runTests(BellyScenarioReporterTest.class);

verify(client, times(1)).startTestItem(any());
ArgumentCaptor<StartTestItemRQ> captor = ArgumentCaptor.forClass(StartTestItemRQ.class);
Expand All @@ -119,7 +120,7 @@ public void verify_code_reference_scenario_reporter() {

@Test
public void verify_code_reference_step_reporter() {
TestUtils.runTests(BellyStepReporter.class);
TestUtils.runTests(BellyStepReporterTest.class);

verify(client, times(1)).startTestItem(any());
ArgumentCaptor<StartTestItemRQ> captor = ArgumentCaptor.forClass(StartTestItemRQ.class);
Expand Down Expand Up @@ -148,7 +149,7 @@ public void verify_code_reference_step_reporter() {

@Test
public void verify_code_reference_two_features_step_reporter() {
TestUtils.runTests(TwoFeaturesStepReporter.class);
TestUtils.runTests(TwoFeaturesStepReporterTest.class);

verify(client, times(1)).startTestItem(any());
ArgumentCaptor<StartTestItemRQ> captor = ArgumentCaptor.forClass(StartTestItemRQ.class);
Expand Down
Loading