Repository: olingo-odata4
Updated Branches:
  refs/heads/master 7dfb6761b -> 53de4ab24


[OLINGO-206] more JUnit


Project: http://git-wip-us.apache.org/repos/asf/olingo-odata4/repo
Commit: http://git-wip-us.apache.org/repos/asf/olingo-odata4/commit/53de4ab2
Tree: http://git-wip-us.apache.org/repos/asf/olingo-odata4/tree/53de4ab2
Diff: http://git-wip-us.apache.org/repos/asf/olingo-odata4/diff/53de4ab2

Branch: refs/heads/master
Commit: 53de4ab240474a3f3eefec5a8f2a985be93e9dde
Parents: 7dfb676
Author: Stephan Klevenz <[email protected]>
Authored: Wed Apr 30 08:44:50 2014 +0200
Committer: Stephan Klevenz <[email protected]>
Committed: Wed Apr 30 08:44:50 2014 +0200

----------------------------------------------------------------------
 .../apache/olingo/server/core/uri/antlr/TestUriParserImpl.java | 2 +-
 .../olingo/server/core/uri/testutil/ResourceValidator.java     | 6 +++++-
 2 files changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/53de4ab2/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/antlr/TestUriParserImpl.java
----------------------------------------------------------------------
diff --git 
a/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/antlr/TestUriParserImpl.java
 
b/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/antlr/TestUriParserImpl.java
index 9950e9c..9a05cfb 100644
--- 
a/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/antlr/TestUriParserImpl.java
+++ 
b/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/antlr/TestUriParserImpl.java
@@ -100,7 +100,7 @@ public class TestUriParserImpl {
   @Test
   public void testFunctionBound_varReturnType() {
 
-    String esTwoKeyNav = "ESTwoKeyNav(ParameterInt16=1,PropertyString='ABC')";
+    String esTwoKeyNav = "ESTwoKeyNav(PropertyInt16=1,PropertyString='ABC')";
 
     // returning primitive
     testRes.run("ESTwoKeyNav/com.sap.odata.test1.BFCESTwoKeyNavRTString()")

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/53de4ab2/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/testutil/ResourceValidator.java
----------------------------------------------------------------------
diff --git 
a/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/testutil/ResourceValidator.java
 
b/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/testutil/ResourceValidator.java
index 072de08..bcededc 100644
--- 
a/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/testutil/ResourceValidator.java
+++ 
b/lib/server-core/src/test/java/org/apache/olingo/server/core/uri/testutil/ResourceValidator.java
@@ -54,6 +54,7 @@ import 
org.apache.olingo.server.core.uri.queryoption.CustomQueryOptionImpl;
 import org.apache.olingo.server.core.uri.queryoption.ExpandOptionImpl;
 import org.apache.olingo.server.core.uri.queryoption.SelectOptionImpl;
 import org.apache.olingo.server.core.uri.queryoption.expression.ExpressionImpl;
+import org.apache.olingo.server.core.uri.validator.UriValidator;
 
 public class ResourceValidator implements TestValidator {
   private Edm edm;
@@ -90,7 +91,10 @@ public class ResourceValidator implements TestValidator {
     uriPathInfo = null;
     try {
       uriInfoTmp = (UriInfoImpl) testParser.parseUri(uri, edm);
-    } catch (UriParserException e) {
+      
+      UriValidator uriValidator = new UriValidator();
+      uriValidator.validate(uriInfoTmp, "GET");
+    } catch (Exception e) {
       fail("Exception occured while parsing the URI: " + uri + "\n"
           + " Message: " + e.getMessage());
     }

Reply via email to