-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathtasks.py
More file actions
27 lines (23 loc) · 747 Bytes
/
Copy pathtasks.py
File metadata and controls
27 lines (23 loc) · 747 Bytes
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
26
27
from invoke import task, run
@task
def installdeps(c):
"""
Instala todas las dependencias
"""
print("Instalar las dependencias")
run ("poetry update && poetry install")
print("Se han instalado correctamente las dependencias")
@task
def check(c):
print("Comprobar la compilación")
run ("python3 -m compileall sportcar/*.py")
print("Compilacion nice!")
@task
def test(c):
print("Lanzamos los test de unittest")
run("python3 -m unittest -v test/test.py")
print("Todo correcto")
@task
def docker(c):
print("Contruimos y ejecutamos los test en el contenedor docker")
run("docker build . --file Dockerfile --tag argelion14/sport-car && docker run -t -v `pwd`:/app/test argelion14/sport-car")