Skip to content
This repository has been archived by the owner on Dec 15, 2021. It is now read-only.

Commit

Permalink
Use runtime go1.14 in integration tests (#1140)
Browse files Browse the repository at this point in the history
  • Loading branch information
sepetrov authored Jun 10, 2020
1 parent 99e950c commit 788ed2b
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions examples/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -136,13 +136,13 @@ get-nodejs-multi-verify:
kubeless function call get-nodejs-multi |egrep hello.world

get-go:
kubeless function deploy get-go --runtime go1.10 --handler handler.Foo --from-file golang/helloget.go
kubeless function deploy get-go --runtime go1.14 --handler handler.Foo --from-file golang/helloget.go

get-go-verify:
kubeless function call get-go |egrep Hello.world

get-go-custom-port:
kubeless function deploy get-go-custom-port --runtime go1.10 --handler helloget.Foo --from-file golang/helloget.go --port 8083
kubeless function deploy get-go-custom-port --runtime go1.14 --handler helloget.Foo --from-file golang/helloget.go --port 8083

get-go-custom-port-verify:
kubectl get svc get-go-custom-port -o yaml | grep 'targetPort: 8083'
Expand All @@ -151,22 +151,22 @@ get-go-custom-port-verify:
timeout-go:
$(eval TMPDIR := $(shell mktemp -d))
printf 'package kubeless\nimport "github.com/kubeless/kubeless/pkg/functions"\nfunc Foo(event functions.Event, context functions.Context) (string, error) {\nfor{\n}\nreturn "", nil\n}' > $(TMPDIR)/hello-loop.js
kubeless function deploy timeout-go --runtime go1.10 --handler helloget.Foo --from-file $(TMPDIR)/hello-loop.js --timeout 4
kubeless function deploy timeout-go --runtime go1.14 --handler helloget.Foo --from-file $(TMPDIR)/hello-loop.js --timeout 4
rm -rf $(TMPDIR)

timeout-go-verify:
$(eval MSG := $(shell kubeless function call timeout-go 2>&1 || true))
echo $(MSG) | egrep Request.timeout.exceeded

get-go-deps:
kubeless function deploy get-go-deps --runtime go1.10 --handler helloget.Hello --from-file golang/hellowithdeps.go --dependencies golang/Gopkg.toml
kubeless function deploy get-go-deps --runtime go1.14 --handler helloget.Hello --from-file golang/hellowithdeps.go --dependencies golang/Gopkg.toml

get-go-deps-verify:
kubeless function call get-go-deps --data '{"hello": "world"}'
kubectl logs --tail=1000 -l function=get-go-deps | grep -q 'level=info msg=.*hello.*world'

post-go:
kubeless function deploy post-go --runtime go1.10 --handler hellowithdata.Handler --from-file golang/hellowithdata.go
kubeless function deploy post-go --runtime go1.14 --handler hellowithdata.Handler --from-file golang/hellowithdata.go

post-go-verify:
kubeless function call post-go --data '{"it-s": "alive"}'| egrep "it.*alive"
Expand Down Expand Up @@ -761,7 +761,7 @@ pubsub-ruby-verify:

pubsub-go:
kubeless topic create s3-go || true
kubeless function deploy pubsub-go --runtime go1.10 --handler pubsub-go.Handler --from-file golang/hellowithdata.go
kubeless function deploy pubsub-go --runtime go1.14 --handler pubsub-go.Handler --from-file golang/hellowithdata.go
kubeless trigger kafka create pubsub-go --function-selector created-by=kubeless,function=pubsub-go --trigger-topic s3-go

pubsub-go-verify:
Expand Down

0 comments on commit 788ed2b

Please sign in to comment.