Skip to content

Commit

Permalink
Remove generate tests and use static test yaml. (#515)
Browse files Browse the repository at this point in the history
* Remove generate tests and use static test yaml.

Since there aren't any more variables in the test yaml, replace
the shell script with a static YAML.

* Print python version

* Remove generate test step
  • Loading branch information
maxking authored Sep 18, 2021
1 parent 9fb38d7 commit b84c09c
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 9 deletions.
5 changes: 2 additions & 3 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ jobs:
key: python-deps-cache-v1
paths:
- /root/.cache
- run:
name: Generate Tests
command: bash tests/generate_tests.sh
- run:
environment:
DB: postgres
Expand All @@ -42,7 +39,9 @@ jobs:
name: MySQL Test
command: bash tests/test.sh
- deploy:
name: Deploy
command: |
python3 --version
python3 deploy.py
workflows:
Expand Down
3 changes: 3 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

set -ex

# Since all the dockerfiles now require buildkit features.
export DOCKER_BUILDKIT=1

# Set the default value of BUILD_ROLLING to no.
export BUILD_ROLLING="${1:-no}"

Expand Down
4 changes: 0 additions & 4 deletions tests/generate_tests.sh → tests/docker-test.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
#!/bin/sh

cat > docker-test.yaml <<EOF
version: '2'

services:
Expand All @@ -11,4 +8,3 @@ services:
image: maxking/mailman-web:rolling
environment:
- SECRET_KEY=abcdefghijklmnopqrstuv
EOF
4 changes: 2 additions & 2 deletions tests/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ set -e
# If the DB environment variable is not set, use postgres.x
if [ "$DB" = "postgres" ] || [ -z $DB ]
then
docker-compose -f docker-compose.yaml -f docker-test.yaml up -d
docker-compose -f docker-compose.yaml -f tests/docker-test.yaml up -d
elif [ "$DB" = "mysql" ]
then
docker-compose -f docker-compose-mysql.yaml -f docker-test.yaml up -d
docker-compose -f docker-compose-mysql.yaml -f tests/docker-test.yaml up -d
fi

# Print the IP Addresses of the Containers.
Expand Down

0 comments on commit b84c09c

Please sign in to comment.