Commit | Line | Data |
---|---|---|
16d59378 NR |
1 | package be.nikiroo.utils.test; |
2 | ||
3 | import java.io.InputStream; | |
4 | ||
5 | import be.nikiroo.utils.IOUtils; | |
6 | ||
7 | public class IOUtilsTest extends TestLauncher { | |
8 | ||
9 | public IOUtilsTest(String[] args) { | |
10 | super("IOUtils test", args); | |
11 | ||
12 | addTest(new TestCase("openResource") { | |
13 | @Override | |
14 | public void test() throws Exception { | |
15 | InputStream in = IOUtils.openResource("VERSION"); | |
16 | assertNotNull( | |
17 | "The VERSION file is supposed to be present in the binaries", | |
18 | in); | |
19 | in.close(); | |
20 | } | |
21 | }); | |
22 | ||
23 | addTest(new TestCase("getVersion") { | |
24 | @Override | |
25 | public void test() throws Exception { | |
26 | assertNotNull("The VERSION is not defined", | |
27 | IOUtils.getVersion()); | |
28 | } | |
29 | }); | |
30 | } | |
31 | } |