File tree Expand file tree Collapse file tree 3 files changed +5
-3
lines changed
jackson-simple/src/test/java/com/baeldung/jackson/objectmapper Expand file tree Collapse file tree 3 files changed +5
-3
lines changed Original file line number Diff line number Diff line change 77import static org .junit .Assert .assertThat ;
88
99import java .io .File ;
10+ import java .net .URI ;
1011import java .net .URL ;
1112import java .util .List ;
1213import java .util .Map ;
@@ -103,7 +104,7 @@ public void wheReadFromFile_thanCorrect() throws Exception {
103104
104105 @ Test
105106 public void wheReadFromUrl_thanCorrect () throws Exception {
106- URL resource = new URL ("file:src/test/resources/json_car.json" );
107+ URL resource = new URI ("file:src/test/resources/json_car.json" ). toURL ( );
107108
108109 ObjectMapper objectMapper = new ObjectMapper ();
109110 Car fromFile = objectMapper .readValue (resource , Car .class );
Original file line number Diff line number Diff line change 5555 <module >testing-modules</module >
5656 <module >toolkits</module >
5757 <module >xml</module >
58+ <module >xml-2</module >
5859 </modules >
5960
6061 <properties >
Original file line number Diff line number Diff line change 88 <name >xml-2</name >
99
1010 <parent >
11- <groupId >com.baeldung </groupId >
11+ <groupId >com.ossez </groupId >
1212 <artifactId >parent-modules</artifactId >
13- <version >1. 0.0-SNAPSHOT</version >
13+ <version >0.0.2 -SNAPSHOT</version >
1414 </parent >
1515
1616 <dependencies >
You can’t perform that action at this time.
0 commit comments