Skip to content
This repository has been archived by the owner on Jan 14, 2019. It is now read-only.

NPE on null parameter (fixes #823) #933

Merged
merged 3 commits into from
Feb 19, 2017
Merged

NPE on null parameter (fixes #823) #933

merged 3 commits into from
Feb 19, 2017

Conversation

sseliverstov
Copy link
Contributor

No description provided.

@@ -457,7 +457,7 @@ private void fireAddParameterEvents(ITestResult iTestResult) {
}

String name = getNameForParameter(parameter.value(), methodParameterNames, i);
String value = parameters[i].toString();
String value = parameters[i] != null ? parameters[i].toString() : "null";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can use Objects.toString(parameters[i]) instead

import java.util.List;
import java.util.Set;
import java.util.UUID;
import java.util.*;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this change

@baev baev merged commit 88a99ee into master Feb 19, 2017
@baev baev deleted the 823-NPE-in-parameters branch February 19, 2017 12:52
@baev baev removed the work:review label Feb 19, 2017
wuhuizuo pushed a commit to wuhuizuo/allure-core that referenced this pull request Apr 1, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants