You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by cs...@apache.org on 2017/06/03 16:05:37 UTC

[incubator-openwhisk] branch master updated: Use unique API Names for unique basepaths (#2329)

This is an automated email from the ASF dual-hosted git repository.

csantanapr pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk.git

The following commit(s) were added to refs/heads/master by this push:
       new  9d86888   Use unique API Names for unique basepaths (#2329)
9d86888 is described below

commit 9d86888d7492728ba9e5c5074aa5d7a742f37001
Author: Mark Deuser <md...@us.ibm.com>
AuthorDate: Sat Jun 3 12:05:34 2017 -0400

    Use unique API Names for unique basepaths (#2329)
    
    - New API GW restriction
---
 tests/src/test/scala/whisk/core/cli/test/ApiGwTests.scala | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/tests/src/test/scala/whisk/core/cli/test/ApiGwTests.scala b/tests/src/test/scala/whisk/core/cli/test/ApiGwTests.scala
index 7df26c1..55d2f16 100644
--- a/tests/src/test/scala/whisk/core/cli/test/ApiGwTests.scala
+++ b/tests/src/test/scala/whisk/core/cli/test/ApiGwTests.scala
@@ -804,6 +804,7 @@ class ApiGwTests
         val testnewrelpath = "/path_new"
         val testurlop = "get"
         val testapiname = testName+" API Name"
+        val testapiname2 = testName+" API Name 2"
         val actionName = testName+"_action"
         val newEndpoint = "/newEndpoint"
         try {
@@ -813,7 +814,7 @@ class ApiGwTests
 
             var rr = apiCreate(basepath = Some(testbasepath), relpath = Some(testrelpath), operation = Some(testurlop), action = Some(actionName), apiname = Some(testapiname))
             rr.stdout should include("ok: created API")
-            rr = apiCreate(basepath = Some(testbasepath2), relpath = Some(testrelpath), operation = Some(testurlop), action = Some(actionName), apiname = Some(testapiname))
+            rr = apiCreate(basepath = Some(testbasepath2), relpath = Some(testrelpath), operation = Some(testurlop), action = Some(actionName), apiname = Some(testapiname2))
             rr.stdout should include("ok: created API")
 
             // Update both APIs - each with a new endpoint
@@ -985,6 +986,7 @@ class ApiGwTests
         val testnewrelpath = "/path_new"
         val testurlop = "get"
         val testapiname = testName + " API Name"
+        val testapiname2 = testName + " API Name 2"
         val actionName = testName + "_action"
         try {
             // Create the action for the API.  It must be a "web-action" action.
@@ -997,7 +999,7 @@ class ApiGwTests
             rr.stdout should include("ok: APIs")
             rr.stdout should include regex (s"/${clinamespace}/${actionName}\\s+${testurlop}\\s+${testapiname}\\s+")
             rr.stdout should include(testbasepath + testrelpath)
-            rr = apiCreate(basepath = Some(testbasepath2), relpath = Some(testrelpath), operation = Some(testurlop), action = Some(actionName), apiname = Some(testapiname))
+            rr = apiCreate(basepath = Some(testbasepath2), relpath = Some(testrelpath), operation = Some(testurlop), action = Some(actionName), apiname = Some(testapiname2))
             rr.stdout should include("ok: created API")
             rr = apiList(basepathOrApiName = Some(testbasepath2), relpath = Some(testrelpath), operation = Some(testurlop))
             rr.stdout should include("ok: APIs")
@@ -1038,7 +1040,6 @@ class ApiGwTests
     it should "reject an API created with an action that is not a web action" in {
         val testName = "CLI_APIGWTEST16"
         val testbasepath = "/" + testName + "_bp"
-        val testbasepath2 = "/" + testName + "_bp2"
         val testrelpath = "/path"
         val testnewrelpath = "/path_new"
         val testurlop = "get"

-- 
To stop receiving notification emails like this one, please contact
['"commits@openwhisk.apache.org" <co...@openwhisk.apache.org>'].