Skip to content

Commit f959ba7

Browse files
committed
test med konverterting
1 parent 078140d commit f959ba7

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

felles/util/pom.xml

+1
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@
7676
<artifactId>maven-surefire-plugin</artifactId>
7777
<configuration>
7878
<environmentVariables>
79+
<VG>http://www.vg.no</VG>
7980
<NAIS_CLUSTER_NAME>prod-fss</NAIS_CLUSTER_NAME>
8081
<NAIS_NAMESPACE>jalla</NAIS_NAMESPACE>
8182
</environmentVariables>

felles/util/src/test/java/no/nav/vedtak/util/env/EnvironmentTest.java

+6-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
import java.io.ByteArrayOutputStream;
1010
import java.io.PrintStream;
11+
import java.net.URI;
1112
import java.time.Duration;
1213

1314
import org.junit.Test;
@@ -22,7 +23,7 @@ public class EnvironmentTest {
2223
private static final Logger LOG = LoggerFactory.getLogger(EnvironmentTest.class);
2324
private static Environment ENV = Environment.current();
2425
private static PrintStream SYSOUT = System.out;
25-
26+
2627
@org.junit.After
2728
public void after() throws Exception {
2829
// reset
@@ -38,6 +39,10 @@ public void testEnvironment() {
3839
assertTrue(ENV.isProd());
3940
}
4041

42+
public void testURI() {
43+
assertEquals(ENV.getRequiredProperty("VG", URI.class), URI.create("http://www.vg.no"));
44+
}
45+
4146
public void testUppercase() {
4247
assertEquals(PROD_FSS.clusterName(), ENV.getProperty("nais.cluster.name"));
4348
}

0 commit comments

Comments
 (0)