jenkinsci/hpe-application-automation-tools-plugin

View on GitHub
src/main/java/com/microfocus/application/automation/tools/results/DetailReport.java

Summary

Maintainability
A
0 mins
Test Coverage

Update this method so that its implementation is not identical to "getDisplayName" on line 61.
Open

    public String getName() {

When two methods have the same implementation, either it was a mistake - something else was intended - or the duplication was intentional, but may be confusing to maintainers. In the latter case, one implementation should invoke the other. Numerical and string literals are not taken into account.

Noncompliant Code Example

private final static String CODE = "bounteous";

public String calculateCode() {
  doTheThing();
  return CODE;
}

public String getName() {  // Noncompliant
  doTheThing();
  return CODE;
}

Compliant Solution

private final static String CODE = "bounteous";

public String getCode() {
  doTheThing();
  return CODE;
}

public String getName() {
  return getCode();
}

Exceptions

Methods that are not accessors (getters and setters), with fewer than 2 statements are ignored.

There are no issues that match your filters.

Category
Status