Verified Commit 5d2b0ead authored by Sheogorath's avatar Sheogorath 🛫

Add CI stage for testing built results

This patch adds a basic test stage that runs some smoke tests on the
service to verify that it's working properly.
parent e16c68c3
Pipeline #4167 passed with stages
in 1 minute and 56 seconds
......@@ -5,12 +5,29 @@ include:
stages:
- build
- test
- tag
- deploy
variables:
CI_REGISTRY_IMAGE_VERSION: "1.3.0"
container-testing:
stage: test
image: quay.io/sheogorath/build-ah-engine:1.3.0
script:
- podman run -d -v $(pwd)/avatar:/var/libravatar.d/:ro -p 127.0.0.1:80:80 "$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG-$CI_COMMIT_SHORT_SHA"
- sleep 60
- curl -q --fail http://localhost/avatar/855c94f3498940b241d6b5e78bb6f9293b941953b2799f8b925bd25180571d77 > example-sha256-default.jpg
- curl -q --fail http://localhost/avatar/855c94f3498940b241d6b5e78bb6f9293b941953b2799f8b925bd25180571d77?size=511 > example-sha256-511.jpg
- curl -q --fail http://localhost/avatar/855c94f3498940b241d6b5e78bb6f9293b941953b2799f8b925bd25180571d77?size=512 > example-sha256-512.jpg
- curl -q --fail http://localhost/avatar/cd11923284fc0f904c4732bb8f7d7e3c > example-md5-default.jpg
- curl -q --fail http://localhost/avatar/cd11923284fc0f904c4732bb8f7d7e3c?size=511 > example-md5-511.jpg
- curl -q --fail http://localhost/avatar/cd11923284fc0f904c4732bb8f7d7e3c?size=512 > example-md5-512.jpg
- cmp example-md5-default.jpg example-sha256-default.jpg
- cmp example-md5-511.jpg example-md5-512.jpg
- cmp example-sha256-511.jpg example-sha256-512.jpg
container-tagging:
only:
variables:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment