You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by ho...@apache.org on 2017/08/29 18:36:45 UTC

[incubator-openwhisk-wskdeploy] branch master updated (37925e4 -> 1216793)

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

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


    from 37925e4  Support more runtime types from bluemix host info. (#366)
     new c9c4ffd  adding back jaraction integration test
     new 1216793  adding newline in java file

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../webaction_test.go => jaraction/jaraction_test.go}       |  10 ++++------
 tests/src/integration/jaraction/manifest.yaml               |   7 +++++++
 .../actions => src/integration/jaraction/src}/Hello.java    |   0
 .../actions => src/integration/jaraction/src}/hello.jar     | Bin
 4 files changed, 11 insertions(+), 6 deletions(-)
 copy tests/src/integration/{webaction/webaction_test.go => jaraction/jaraction_test.go} (88%)
 create mode 100644 tests/src/integration/jaraction/manifest.yaml
 copy tests/{usecases/helloworld/actions => src/integration/jaraction/src}/Hello.java (100%)
 copy tests/{usecases/helloworld/actions => src/integration/jaraction/src}/hello.jar (100%)

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

[incubator-openwhisk-wskdeploy] 01/02: adding back jaraction integration test

Posted by ho...@apache.org.
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-wskdeploy.git

commit c9c4ffd68042821a45a56abeab002adde05950e6
Author: Priti Desai <pd...@us.ibm.com>
AuthorDate: Tue Aug 29 10:55:42 2017 -0700

    adding back jaraction integration test
---
 tests/src/integration/jaraction/jaraction_test.go |  42 ++++++++++++++++++++++
 tests/src/integration/jaraction/manifest.yaml     |   7 ++++
 tests/src/integration/jaraction/src/Hello.java    |  28 +++++++++++++++
 tests/src/integration/jaraction/src/hello.jar     | Bin 0 -> 966 bytes
 4 files changed, 77 insertions(+)

diff --git a/tests/src/integration/jaraction/jaraction_test.go b/tests/src/integration/jaraction/jaraction_test.go
new file mode 100644
index 0000000..3c9f464
--- /dev/null
+++ b/tests/src/integration/jaraction/jaraction_test.go
@@ -0,0 +1,42 @@
+// +build integration
+
+/*
+ * 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 tests
+
+import (
+	"github.com/apache/incubator-openwhisk-wskdeploy/tests/src/integration/common"
+	"github.com/stretchr/testify/assert"
+	"os"
+	"testing"
+)
+
+var wskprops = common.GetWskprops()
+
+func TestJarAction(t *testing.T) {
+	wskdeploy := common.NewWskdeploy()
+	_, err := wskdeploy.Deploy(manifestPath, deploymentPath)
+	assert.Equal(t, nil, err, "Failed to deploy based on the manifest and deployment files.")
+	_, err = wskdeploy.Undeploy(manifestPath, deploymentPath)
+	assert.Equal(t, nil, err, "Failed to undeploy based on the manifest and deployment files.")
+}
+
+var (
+	manifestPath   = os.Getenv("GOPATH") + "/src/github.com/apache/incubator-openwhisk-wskdeploy/tests/src/integration/jaraction/manifest.yaml"
+	deploymentPath = ""
+)
diff --git a/tests/src/integration/jaraction/manifest.yaml b/tests/src/integration/jaraction/manifest.yaml
new file mode 100644
index 0000000..dfb83a9
--- /dev/null
+++ b/tests/src/integration/jaraction/manifest.yaml
@@ -0,0 +1,7 @@
+package:
+    name: IntegrationTestHelloworldJar
+    actions:
+        hellojaraction:
+            function: src/hello.jar
+            runtime: java
+            main: Hello
\ No newline at end of file
diff --git a/tests/src/integration/jaraction/src/Hello.java b/tests/src/integration/jaraction/src/Hello.java
new file mode 100644
index 0000000..016a88e
--- /dev/null
+++ b/tests/src/integration/jaraction/src/Hello.java
@@ -0,0 +1,28 @@
+/*
+ * 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.
+ */
+
+import com.google.gson.JsonObject;
+public class Hello {
+    public static JsonObject main(JsonObject args) {
+        String name = "stranger";
+        if (args.has("name"))
+            name = args.getAsJsonPrimitive("name").getAsString();
+        JsonObject response = new JsonObject();
+        response.addProperty("greeting", "Hello " + name + "!");
+        return response;
+    }
+}
\ No newline at end of file
diff --git a/tests/src/integration/jaraction/src/hello.jar b/tests/src/integration/jaraction/src/hello.jar
new file mode 100644
index 0000000..b05753f
Binary files /dev/null and b/tests/src/integration/jaraction/src/hello.jar differ

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

[incubator-openwhisk-wskdeploy] 02/02: adding newline in java file

Posted by ho...@apache.org.
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-wskdeploy.git

commit 1216793ee6cfec3793dea33c5e6ac5f7248e32be
Author: Priti Desai <pd...@us.ibm.com>
AuthorDate: Tue Aug 29 11:08:52 2017 -0700

    adding newline in java file
---
 tests/src/integration/jaraction/src/Hello.java | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/src/integration/jaraction/src/Hello.java b/tests/src/integration/jaraction/src/Hello.java
index 016a88e..33b2396 100644
--- a/tests/src/integration/jaraction/src/Hello.java
+++ b/tests/src/integration/jaraction/src/Hello.java
@@ -25,4 +25,5 @@ public class Hello {
         response.addProperty("greeting", "Hello " + name + "!");
         return response;
     }
-}
\ No newline at end of file
+}
+

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