Skip to content

Commit 6082ac9

Browse files
committed
Fix test
1 parent 678e47d commit 6082ac9

1 file changed

Lines changed: 9 additions & 14 deletions

File tree

‎core-java/src/test/java/com/baeldung/file/FileOperationsUnitTest.java‎

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
package com.baeldung.file;
22

3-
import java.io.BufferedReader;
4-
import java.io.File;
5-
import java.io.FileInputStream;
6-
import java.io.IOException;
7-
import java.io.InputStream;
8-
import java.io.InputStreamReader;
3+
import org.apache.commons.io.FileUtils;
4+
import org.hamcrest.CoreMatchers;
5+
import org.hamcrest.Matchers;
6+
import org.junit.Assert;
7+
import org.junit.Test;
8+
9+
import java.io.*;
910
import java.net.URISyntaxException;
1011
import java.net.URL;
1112
import java.net.URLConnection;
@@ -14,12 +15,6 @@
1415
import java.nio.file.Paths;
1516
import java.util.stream.Stream;
1617

17-
import org.apache.commons.io.FileUtils;
18-
import org.hamcrest.CoreMatchers;
19-
import org.hamcrest.Matchers;
20-
import org.junit.Assert;
21-
import org.junit.Test;
22-
2318
public class FileOperationsUnitTest {
2419

2520
@Test
@@ -58,9 +53,9 @@ public void givenFileName_whenUsingJarFile_thenFileData() throws IOException {
5853

5954
@Test
6055
public void givenURLName_whenUsingURL_thenFileData() throws IOException {
61-
String expectedData = "Baeldung";
56+
String expectedData = "Example Domain";
6257

63-
URL urlObject = new URL("http://www.baeldung.com/");
58+
URL urlObject = new URL("http://www.example.com/");
6459

6560
URLConnection urlConnection = urlObject.openConnection();
6661

0 commit comments

Comments
 (0)