File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed
src/test/java/org/scijava/io Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change 3333
3434import static org .junit .Assert .assertEquals ;
3535
36+ import java .io .File ;
37+
3638import org .junit .Test ;
3739
3840/**
@@ -47,7 +49,14 @@ public class FileLocationTest {
4749 public void testFile () {
4850 final String path = "/not/actually/a/real-file" ;
4951 final FileLocation loc = new FileLocation (path );
50- assertEquals (path , loc .getFile ().getPath ());
52+ final File realFile = loc .getFile ();
53+ assertEquals ("real-file" , realFile .getName ());
54+ final File a = realFile .getParentFile ();
55+ assertEquals ("a" , a .getName ());
56+ final File actually = a .getParentFile ();
57+ assertEquals ("actually" , actually .getName ());
58+ final File not = actually .getParentFile ();
59+ assertEquals ("not" , not .getName ());
5160 }
5261
5362}
You can’t perform that action at this time.
0 commit comments