tamaya-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anat...@apache.org
Subject incubator-tamaya git commit: Added tests to increase coverage.
Date Thu, 21 May 2015 11:01:28 GMT
Repository: incubator-tamaya
Updated Branches:
  refs/heads/master 4a0db69c1 -> 7c6a09665


Added tests to increase coverage.


Project: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/commit/7c6a0966
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/tree/7c6a0966
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tamaya/diff/7c6a0966

Branch: refs/heads/master
Commit: 7c6a09665481284600657e3f5f1069c6a2624de5
Parents: 4a0db69
Author: anatole <anatole@apache.org>
Authored: Thu May 21 13:01:21 2015 +0200
Committer: anatole <anatole@apache.org>
Committed: Thu May 21 13:01:21 2015 +0200

----------------------------------------------------------------------
 .../apache/tamaya/resolver/ResolverTest.java    | 41 ++++++++++++++++++++
 1 file changed, 41 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tamaya/blob/7c6a0966/modules/resolver/src/test/java/org/apache/tamaya/resolver/ResolverTest.java
----------------------------------------------------------------------
diff --git a/modules/resolver/src/test/java/org/apache/tamaya/resolver/ResolverTest.java b/modules/resolver/src/test/java/org/apache/tamaya/resolver/ResolverTest.java
new file mode 100644
index 0000000..74c9d84
--- /dev/null
+++ b/modules/resolver/src/test/java/org/apache/tamaya/resolver/ResolverTest.java
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.tamaya.resolver;
+
+import org.junit.Test;
+
+import static org.junit.Assert.*;
+
+/**
+ * Tests for {@link org.apache.tamaya.resolver.Resolver}.
+ */
+public class ResolverTest {
+
+    @Test
+    public void testEvaluateExpression() throws Exception {
+        assertEquals(Resolver.evaluateExpression("myKey", "Version ${java.version}"),
+                "Version " + System.getProperty("java.version"));
+    }
+
+    @Test
+    public void testEvaluateExpression1() throws Exception {
+        assertEquals(Resolver.evaluateExpression("Version ${java.version}"),
+                "Version " + System.getProperty("java.version"));
+    }
+}
\ No newline at end of file


Mime
View raw message