File tree Expand file tree Collapse file tree 7 files changed +101
-10
lines changed Expand file tree Collapse file tree 7 files changed +101
-10
lines changed Original file line number Diff line number Diff line change @@ -61,14 +61,6 @@ ansible/roles/nginx/files/openwhisk-client*
61
61
ansible /roles /nginx /files /* .csr
62
62
ansible /roles /nginx /files /* cert.pem
63
63
64
- # .zip files must be explicited whitelisted
64
+ # Generated by tests:buildArtifacts
65
+ .built
65
66
* .zip
66
- ! tests /dat /actions /blackbox.zip
67
- ! tests /dat /actions /helloSwift.zip
68
- ! tests /dat /actions /nodejs-test.zip
69
- ! tests /dat /actions /python.zip
70
- ! tests /dat /actions /python2_virtualenv.zip
71
- ! tests /dat /actions /python3_virtualenv.zip
72
- ! tests /dat /actions /python_virtualenv_dir.zip
73
- ! tests /dat /actions /python_virtualenv_name.zip
74
- ! tests /dat /actions /zippedaction.zip
Original file line number Diff line number Diff line change @@ -42,3 +42,14 @@ dependencies {
42
42
tasks. withType(ScalaCompile ) {
43
43
scalaCompileOptions. additionalParameters = gradle. scala. compileFlags
44
44
}
45
+
46
+ task buildArtifacts (type :Exec ) {
47
+ workingDir ' tests/dat/actions'
48
+ commandLine ' ./build.sh'
49
+ }
50
+
51
+ tasks. withType(Test ) {
52
+ dependsOn buildArtifacts
53
+ }
54
+
55
+ testClasses. dependsOn(buildArtifacts)
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+ #
3
+ # Licensed to the Apache Software Foundation (ASF) under one or more
4
+ # contributor license agreements. See the NOTICE file distributed with
5
+ # this work for additional information regarding copyright ownership.
6
+ # The ASF licenses this file to You under the Apache License, Version 2.0
7
+ # (the "License"); you may not use this file except in compliance with
8
+ # the License. You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ set -e
20
+
21
+ if [ -f " .built" ]; then
22
+ echo " Test zip artifacts already built, skipping"
23
+ exit 0
24
+ fi
25
+
26
+ (cd nodejs-test && zip ../nodejs-test.zip -r .)
27
+
28
+ touch .built
Original file line number Diff line number Diff line change
1
+ /*
2
+ * Licensed to the Apache Software Foundation (ASF) under one or more
3
+ * contributor license agreements. See the NOTICE file distributed with
4
+ * this work for additional information regarding copyright ownership.
5
+ * The ASF licenses this file to You under the Apache License, Version 2.0
6
+ * (the "License"); you may not use this file except in compliance with
7
+ * the License. You may obtain a copy of the License at
8
+ *
9
+ * http://www.apache.org/licenses/LICENSE-2.0
10
+ *
11
+ * Unless required by applicable law or agreed to in writing, software
12
+ * distributed under the License is distributed on an "AS IS" BASIS,
13
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ * See the License for the specific language governing permissions and
15
+ * limitations under the License.
16
+ */
17
+
18
+ function main ( args ) {
19
+ let x = require ( 'abcxyz' )
20
+ return { "message" : x ( ) } ;
21
+ }
22
+
23
+ module . exports = {
24
+ main : main ,
25
+ niam : main
26
+ }
Original file line number Diff line number Diff line change
1
+ {
2
+ "name" : " nodejs-zip" ,
3
+ "version" : " 1.0.0" ,
4
+ "description" : " Zip to test NodeJS runtime against" ,
5
+ "main" : " main.js" ,
6
+ "scripts" : {
7
+ "test" : " echo \" Error: no test specified\" && exit 1"
8
+ },
9
+ "author" : " " ,
10
+ "license" : " ISC" ,
11
+ "dependencies" : {
12
+ "openwhisk" : " ^2.0.0"
13
+ }
14
+ }
You can’t perform that action at this time.
0 commit comments