Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
elharo committed Dec 14, 2024
1 parent 6caa0b5 commit 676ffbe
Showing 1 changed file with 1 addition and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,6 @@
public abstract class AbstractPmdReportTestCase extends AbstractMojoTestCase {
private ArtifactStubFactory artifactStubFactory;

/**
* The project to test.
*/
private MavenProject testMavenProject;

@Override
protected void setUp() throws Exception {
super.setUp();
Expand Down Expand Up @@ -110,8 +105,6 @@ protected File generateReport(AbstractPmdReport mojo, File pluginXmlFile) throws
ProjectBuildingRequest buildingRequest = new DefaultProjectBuildingRequest();
buildingRequest.setRepositorySession(lookup(LegacySupport.class).getRepositorySession());

testMavenProject = builder.build(pluginXmlFile, buildingRequest).getProject();

File outputDir = mojo.getReportOutputDirectory();
String filename = mojo.getOutputName() + ".html";

Expand All @@ -122,7 +115,7 @@ protected File generateReport(AbstractPmdReport mojo, File pluginXmlFile) throws
* Read the contents of the specified file object into a string.
*/
protected String readFile(File file) throws IOException {
return new String(Files.readAllBytes(file.toPath()), "UTF-8");
return new String(Files.readAllBytes(file.toPath()));
}

/**
Expand Down

0 comments on commit 676ffbe

Please sign in to comment.