File tree Expand file tree Collapse file tree 2 files changed +27
-8
lines changed Expand file tree Collapse file tree 2 files changed +27
-8
lines changed Original file line number Diff line number Diff line change @@ -13,14 +13,36 @@ jobs:
13
13
steps :
14
14
- name : Install Docker Buildx
15
15
uses : docker/setup-buildx-action@v2
16
- - name : Set up Python
17
- uses : actions/setup-python@v5
18
- with :
19
- python-version : ' 3.11'
20
-
16
+ - name : Checkout Repo
17
+ uses : actions/checkout@v4
21
18
- name : Build Docker image
22
19
working-directory : ./app
23
20
run : |
24
21
docker buildx build \
25
22
--platform linux/amd64,linux/arm64 \
26
23
.
24
+
25
+ test :
26
+ runs-on : ubuntu-latest
27
+ permissions :
28
+ contents : read
29
+
30
+ steps :
31
+ - name : Install poetry
32
+ run : pipx install poetry
33
+
34
+ - name : Checkout Repo
35
+ uses : actions/checkout@v4
36
+
37
+ - name : Set up cache for Poetry dependencies
38
+ uses : actions/cache@v4
39
+ with :
40
+ path : ~/.cache/pypoetry
41
+ key : poetry-${{ hashFiles('app/poetry.lock') }}
42
+
43
+ - name : Install Python dependencies with Poetry
44
+ working-directory : ./app
45
+ run : poetry install --no-interaction --no-root
46
+
47
+ - name : Run intercom test
48
+ run : python app/test_intercom.py
Original file line number Diff line number Diff line change @@ -37,9 +37,6 @@ COPY . /app
37
37
# Expose port 5050 for the Flask application
38
38
EXPOSE 5050
39
39
40
- # Run test file
41
- RUN python test_intercom.py
42
-
43
40
# Define environment variable for Flask
44
41
ENV FLASK_APP=app.py
45
42
You can’t perform that action at this time.
0 commit comments