@@ -60,7 +60,7 @@ public void formattingUsingConfigFile() throws Exception {
60
60
npmExecutable (),
61
61
new PrettierConfig (prettierRc , null ));
62
62
63
- try (StepHarnessWithFile stepHarness = StepHarnessWithFile .forStep (formatterStep )) {
63
+ try (StepHarness stepHarness = StepHarness .forStep (formatterStep )) {
64
64
stepHarness .testResource (dirtyFile , cleanFile );
65
65
}
66
66
}
@@ -83,7 +83,7 @@ public void parserInferenceBasedOnExplicitFilepathIsWorking() throws Exception {
83
83
npmExecutable (),
84
84
new PrettierConfig (null , ImmutableMap .of ("filepath" , "anyname.json" ))); // should select parser based on this name
85
85
86
- try (StepHarnessWithFile stepHarness = StepHarnessWithFile .forStep (formatterStep )) {
86
+ try (StepHarness stepHarness = StepHarness .forStep (formatterStep )) {
87
87
stepHarness .testResource (dirtyFile , cleanFile );
88
88
}
89
89
}
@@ -103,7 +103,7 @@ public void parserInferenceBasedOnFilenameIsWorking() throws Exception {
103
103
new PrettierConfig (null , Collections .emptyMap ()));
104
104
105
105
try (StepHarnessWithFile stepHarness = StepHarnessWithFile .forStep (formatterStep )) {
106
- stepHarness .testResource (dirtyFile , cleanFile );
106
+ stepHarness .testResource (new File ( "test.json" ), dirtyFile , cleanFile );
107
107
}
108
108
}
109
109
@@ -115,7 +115,7 @@ public void verifyPrettierErrorMessageIsRelayed() throws Exception {
115
115
buildDir (),
116
116
npmExecutable (),
117
117
new PrettierConfig (null , ImmutableMap .of ("parser" , "postcss" )));
118
- try (StepHarnessWithFile stepHarness = StepHarnessWithFile .forStep (formatterStep )) {
118
+ try (StepHarness stepHarness = StepHarness .forStep (formatterStep )) {
119
119
stepHarness .testException ("npm/prettier/filetypes/scss/scss.dirty" , exception -> {
120
120
exception .hasMessageContaining ("HTTP 501" );
121
121
exception .hasMessageContaining ("Couldn't resolve parser \" postcss\" " );
@@ -141,7 +141,7 @@ public void runFormatTest(PrettierConfig config, String cleanFileNameSuffix) thr
141
141
npmExecutable (),
142
142
config ); // should select parser based on this name
143
143
144
- try (StepHarnessWithFile stepHarness = StepHarnessWithFile .forStep (formatterStep )) {
144
+ try (StepHarness stepHarness = StepHarness .forStep (formatterStep )) {
145
145
stepHarness .testResource (dirtyFile , cleanFile );
146
146
}
147
147
}
0 commit comments