diff options
Diffstat (limited to 'same/src/test')
-rw-r--r-- | same/src/test/java/com/orbekk/same/config/ConfigurationTest.java | 17 | ||||
-rw-r--r-- | same/src/test/resources/com/orbekk/same/config/test.properties | 1 |
2 files changed, 18 insertions, 0 deletions
diff --git a/same/src/test/java/com/orbekk/same/config/ConfigurationTest.java b/same/src/test/java/com/orbekk/same/config/ConfigurationTest.java new file mode 100644 index 0000000..e5b42aa --- /dev/null +++ b/same/src/test/java/com/orbekk/same/config/ConfigurationTest.java @@ -0,0 +1,17 @@ +package com.orbekk.same.config; + +import static org.junit.Assert.*; + +import org.junit.Test; + +public class ConfigurationTest { + @Test public void testLoadConfiguration() { + String resources = "src/test/resources/"; + System.setProperty(Configuration.configurationProperty, + resources + "com/orbekk/same/config/test.properties"); + Configuration configuration = Configuration.load(); + assertEquals("Test Value", + configuration.getProperty("testProperty")); + + } +} diff --git a/same/src/test/resources/com/orbekk/same/config/test.properties b/same/src/test/resources/com/orbekk/same/config/test.properties new file mode 100644 index 0000000..45e1cc4 --- /dev/null +++ b/same/src/test/resources/com/orbekk/same/config/test.properties @@ -0,0 +1 @@ +testProperty=Test Value |