-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
25 lines (19 loc) · 1022 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
start:
docker-compose up --build -d
stop:
docker-compose down --volumes
initdb:
@docker-compose exec sage-ecr python3 -c 'from ecrdb import EcrDB; db = EcrDB(); db.initdb()'
# TODO(sean) eventually the unit tests can setup their own test database and will run initdb automatically as part of the test suite.
# for now, we just ensure it's run before running the test suite.
test:
@docker-compose exec sage-ecr python3 -c 'from ecrdb import EcrDB; db = EcrDB(); db.initdb()'
@docker-compose exec sage-ecr /bin/bash -c 'coverage run -m pytest -v; coverage report -m; coverage html'
# TODO(sean) unify this with make test so it's oblivious to whether it has a tty or not.
test-no-tty:
@docker-compose exec -T sage-ecr python3 -c 'from ecrdb import EcrDB; db = EcrDB(); db.initdb()'
@docker-compose exec -T sage-ecr /bin/bash -c 'coverage run -m pytest -v; coverage report -m; coverage html'
dbshell:
@docker-compose exec db mysql -u sage --password=test SageECR
registryshell:
@docker-compose exec registry sh