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

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

commit 05f2c145682f9d0278b96f4d38bdc971135c602c
Author: Vincent Hou <s...@us.ibm.com>
AuthorDate: Thu Jun 22 11:04:50 2017 -0400

    Fix the existing integration tests
    
    After a sync-up with openwhisk for the updated cli, the integration
    tests in Go has to be updated with the new messages.
---
 .appveyor.yml                             |  2 +-
 .travis.yml                               |  2 --
 tests/src/integration/integration_test.go | 10 +++++++---
 tools/travis/install_openwhisk.sh         | 10 +++++++---
 4 files changed, 15 insertions(+), 9 deletions(-)

diff --git a/.appveyor.yml b/.appveyor.yml
index 1c79b2c..dc262e3 100644
--- a/.appveyor.yml
+++ b/.appveyor.yml
@@ -1,4 +1,4 @@
-clone_folder: c:\gopath\src\github.com\openwhisk\openwhisk-cli
+clone_folder: c:\gopath\src\github.com\apache\incubator-openwhisk-cli
 
 environment:
   GOPATH: c:\gopath
diff --git a/.travis.yml b/.travis.yml
index ccb9f4e..e773f69 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -34,9 +34,7 @@ script:
   - export PATH=$PATH:$TRAVIS_BUILD_DIR;
   - make native_test;
   - if [ "$TRAVIS_OS_NAME" == "linux" ] ; then
-      export OPENWHISK_HOME="$(dirname "$TRAVIS_BUILD_DIR")/openwhisk";
       ./tools/travis/test_openwhisk.sh;
-      make integration_test;
     fi
 
 after_script:
diff --git a/tests/src/integration/integration_test.go 
b/tests/src/integration/integration_test.go
index 3224e09..5a2bc6b 100644
--- a/tests/src/integration/integration_test.go
+++ b/tests/src/integration/integration_test.go
@@ -31,9 +31,9 @@ var invalidArgs []common.InvalidArg
 var invalidArgsMsg = "error: Invalid argument(s)"
 var tooFewArgsMsg = invalidArgsMsg + "."
 var tooManyArgsMsg = invalidArgsMsg + ": "
-var actionNameActionReqMsg = "An action name and action are required."
+var actionNameActionReqMsg = "An action name and code artifact are required."
 var actionNameReqMsg = "An action name is required."
-var actionOptMsg = "An action is optional."
+var actionOptMsg = "A code artifact is optional."
 var packageNameReqMsg = "A package name is required."
 var packageNameBindingReqMsg = "A package name and binding name are required."
 var ruleNameReqMsg = "A rule name is required."
@@ -469,7 +469,11 @@ func TestRejectCommInvalidArgs(t *testing.T) {
         stdout, err := wsk.RunCommand(cs...)
         outputString := string(stdout)
         assert.NotEqual(t, nil, err, "The command should fail to run.")
-        assert.Equal(t, "exit status 1", err.Error(), "The error should be 
exit status 1.")
+        if (err.Error() == "exit status 1") {
+            assert.Equal(t, "exit status 1", err.Error(), "The error should be 
exit status 1 or 2.")
+        } else {
+            assert.Equal(t, "exit status 2", err.Error(), "The error should be 
exit status 1 or 2.")
+        }
         assert.Contains(t, outputString, invalidArg.Err,
             "The output of the command does not contain " + invalidArg.Err)
         assert.Contains(t, outputString, "Run 'wsk --help' for usage",
diff --git a/tools/travis/install_openwhisk.sh 
b/tools/travis/install_openwhisk.sh
index b5994af..4bc601c 100755
--- a/tools/travis/install_openwhisk.sh
+++ b/tools/travis/install_openwhisk.sh
@@ -1,13 +1,16 @@
 #!/usr/bin/env bash
 
+set -e
+
+export OPENWHISK_HOME="$(dirname "$TRAVIS_BUILD_DIR")/incubator-openwhisk";
 HOMEDIR="$(dirname "$TRAVIS_BUILD_DIR")"
 cd $HOMEDIR
 
 # Clone the OpenWhisk code
-git clone --depth 3 https://github.com/openwhisk/openwhisk.git
+git clone --depth 3 https://github.com/apache/incubator-openwhisk.git
 
 # Build script for Travis-CI.
-WHISKDIR="$HOMEDIR/openwhisk"
+WHISKDIR="$OPENWHISK_HOME"
 
 cd $WHISKDIR
 ./tools/travis/setup.sh
@@ -35,9 +38,10 @@ cp $TRAVIS_BUILD_DIR/wsk $WHISKDIR/bin
 # Run the test cases under openwhisk to ensure the quality of the binary.
 cd $WHISKDIR
 ./gradlew :tests:test -Dtest.single=Wsk*Tests*
-sleep 30
 ./gradlew tests:test -Dtest.single=*ApiGwRoutemgmtActionTests*
 sleep 30
 ./gradlew tests:test -Dtest.single=*ApiGwTests*
 sleep 30
 ./gradlew tests:test -Dtest.single=*ApiGwEndToEndTests*
+sleep 30
+make integration_test;
\ No newline at end of file

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

Reply via email to