Skip to content

Commit

Permalink
Fix BufStepTest for the changes we've had in test infrastructure.
Browse files Browse the repository at this point in the history
  • Loading branch information
nedtwigg committed Jul 16, 2023
1 parent 6e7556f commit 0943a81
Showing 1 changed file with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,18 @@
*/
package com.diffplug.spotless.protobuf;

import java.io.File;

import org.junit.jupiter.api.Test;

import com.diffplug.spotless.ResourceHarness;
import com.diffplug.spotless.StepHarnessWithFile;
import com.diffplug.spotless.tag.BufTest;

@BufTest
class BufStepTest {
class BufStepTest extends ResourceHarness {
@Test
void test() throws Exception {
try (StepHarnessWithFile harness = StepHarnessWithFile.forStep(BufStep.withVersion(BufStep.defaultVersion()).create())) {
harness.testResource(new File("src/main/resources/protobuf/buf/buf.proto"), "protobuf/buf/buf.proto", "protobuf/buf/buf.proto.clean");
try (StepHarnessWithFile harness = StepHarnessWithFile.forStep(this, BufStep.withVersion(BufStep.defaultVersion()).create())) {
harness.testResource("protobuf/buf/buf.proto", "protobuf/buf/buf.proto.clean");
}
}
}

0 comments on commit 0943a81

Please sign in to comment.