Skip to content

Commit

Permalink
Merge pull request #105 from reportportal/develop
Browse files Browse the repository at this point in the history
Release
  • Loading branch information
HardNorth authored Jan 24, 2024
2 parents 28efe4a + 838ff48 commit 34873e6
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 10 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Changelog

## [Unreleased]
### Changed
- Client version updated on [5.2.1](https://github.com/reportportal/client-java/releases/tag/5.2.1), by @HardNorth

## [5.1.3]
### Changed
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
> after a successful launch start. This information might help us to improve both ReportPortal backend and client sides. It is used by the
> ReportPortal team only and is not supposed for sharing with 3rd parties.
[![Maven Central](https://img.shields.io/maven-central/v/com.epam.reportportal/agent-java-junit.svg?label=Maven%20Central)](https://search.maven.org/search?q=g:%22com.epam.reportportal%22%20AND%20a:%22agent-java-junit%22)
[![Maven Central](https://img.shields.io/maven-central/v/com.epam.reportportal/agent-java-junit.svg?label=Maven%20Central)](https://central.sonatype.com/artifact/com.epam.reportportal/agent-java-junit)
[![CI Build](https://github.com/reportportal/agent-java-junit/actions/workflows/ci.yml/badge.svg)](https://github.com/reportportal/agent-java-junit/actions/workflows/ci.yml)
[![Join Slack chat!](https://reportportal-slack-auto.herokuapp.com/badge.svg)](https://reportportal-slack-auto.herokuapp.com)
[![stackoverflow](https://img.shields.io/badge/reportportal-stackoverflow-orange.svg?style=flat)](http://stackoverflow.com/questions/tagged/reportportal)
Expand Down
2 changes: 1 addition & 1 deletion README_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
> after a successful launch start. This information might help us to improve both ReportPortal backend and client sides. It is used by the
> ReportPortal team only and is not supposed for sharing with 3rd parties.
[![Maven Central](https://img.shields.io/maven-central/v/com.epam.reportportal/agent-java-junit.svg?label=Maven%20Central)](https://search.maven.org/search?q=g:%22com.epam.reportportal%22%20AND%20a:%22agent-java-junit%22)
[![Maven Central](https://img.shields.io/maven-central/v/com.epam.reportportal/agent-java-junit.svg?label=Maven%20Central)](https://central.sonatype.com/artifact/com.epam.reportportal/agent-java-junit)
[![CI Build](https://github.com/reportportal/agent-java-junit/actions/workflows/ci.yml/badge.svg)](https://github.com/reportportal/agent-java-junit/actions/workflows/ci.yml)
[![Join Slack chat!](https://reportportal-slack-auto.herokuapp.com/badge.svg)](https://reportportal-slack-auto.herokuapp.com)
[![stackoverflow](https://img.shields.io/badge/reportportal-stackoverflow-orange.svg?style=flat)](http://stackoverflow.com/questions/tagged/reportportal)
Expand Down
7 changes: 4 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ repositories {
}

dependencies {
api 'com.epam.reportportal:client-java:5.1.22'
api 'com.epam.reportportal:client-java:5.2.1'
api 'com.epam.reportportal:commons-model:5.0.0'
api 'com.nordstrom.tools:junit-foundation:17.0.3'
api 'com.google.code.findbugs:jsr305:3.0.2'
Expand All @@ -40,8 +40,8 @@ dependencies {
testImplementation 'org.hamcrest:hamcrest-core:2.2'
testImplementation "org.mockito:mockito-core:${project.mockito_version}"
testImplementation "org.mockito:mockito-junit-jupiter:${project.mockito_version}"
testImplementation 'ch.qos.logback:logback-classic:1.3.8'
testImplementation 'com.epam.reportportal:logger-java-logback:5.1.6'
testImplementation 'ch.qos.logback:logback-classic:1.3.12'
testImplementation 'com.epam.reportportal:logger-java-logback:5.2.0'
testImplementation ("org.junit.platform:junit-platform-runner:${project.junit5_runner_version}") {
exclude module: 'junit'
}
Expand All @@ -52,6 +52,7 @@ dependencies {
testImplementation 'pl.pragmatists:JUnitParams:1.1.1'
testImplementation "org.powermock:powermock-module-junit4:${project.powermock_version}"
testImplementation "org.powermock:powermock-api-mockito2:${project.powermock_version}"
testImplementation 'com.squareup.okhttp3:okhttp:4.12.0'
}

test {
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version=5.1.4-SNAPSHOT
version=5.2.0-SNAPSHOT
description=ReportPortal JUnit 4 client
junit5_version=5.6.3
junit5_runner_version=1.6.3
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -958,17 +958,20 @@ protected List<ParameterResource> getMethodParameters(@Nonnull final FrameworkMe
try {
Optional<Constructor<?>> constructor = Arrays.stream(method.getDeclaringClass().getConstructors()).findFirst();
if (constructor.isPresent()) {
result.addAll(ParameterUtils.getParameters(constructor.get(),
Arrays.asList((Object[]) Accessible.on(runner).field("parameters").getValue())
));
Object[] params = (Object[]) Accessible.on(runner).field("parameters").getValue();
if(params != null) {
result.addAll(ParameterUtils.getParameters(constructor.get(), Arrays.asList(params)));
}
}
} catch (NoSuchFieldException e) {
LOGGER.warn("Unable to get parameters for parameterized runner", e);
}
} else if (callable != null) {
try {
Object[] params = (Object[]) Accessible.on(callable).field("val$params").getValue();
result.addAll(ParameterUtils.getParameters(method.getMethod(), Arrays.asList(params)));
if(params != null) {
result.addAll(ParameterUtils.getParameters(method.getMethod(), Arrays.asList(params)));
}
} catch (NoSuchFieldException e) {
LOGGER.warn("Unable to get parameters for parameterized runner", e);
}
Expand Down

0 comments on commit 34873e6

Please sign in to comment.