Skip to content

Commit 77390a4

Browse files
authored
Fix test NPE (#464)
1 parent 45d2358 commit 77390a4

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

src/test/java/com/networknt/schema/Issue451Test.java

+12-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import com.networknt.schema.walk.WalkFlow;
88
import org.junit.jupiter.api.AfterEach;
99
import org.junit.jupiter.api.Assertions;
10-
import org.junit.jupiter.api.Disabled;
10+
import org.junit.jupiter.api.BeforeAll;
1111
import org.junit.jupiter.api.Test;
1212

1313
import java.io.InputStream;
@@ -34,8 +34,19 @@ protected JsonNode getJsonNodeFromStreamContent(InputStream content) throws Exce
3434
return mapper.readTree(content);
3535
}
3636

37+
38+
@BeforeAll
39+
public static void beforeAll() {
40+
reset();
41+
}
42+
3743
@AfterEach
3844
public void cleanup() {
45+
reset();
46+
}
47+
48+
49+
private static void reset() {
3950
if (CollectorContext.getInstance() != null) {
4051
CollectorContext.getInstance().reset();
4152
}

0 commit comments

Comments
 (0)