-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: updates the E2E test implementation
Replaces Flask and uses WireMock with a JSON mapping Removes E2E from CI (to be used locally) Uses podman play kube to build and teardown the pod and container Signed-off-by: Jennifer Power <[email protected]>
- Loading branch information
Showing
11 changed files
with
102 additions
and
167 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,3 @@ | ||
FROM python:3.8-slim | ||
FROM docker.io/wiremock/wiremock:3.2.0-2 | ||
|
||
WORKDIR /app | ||
|
||
COPY mock_api.py /app | ||
|
||
RUN pip install -no-cache-dir Flask==3.0.0 | ||
|
||
CMD ["python3", "mock_api.py"] | ||
COPY mappings/ /home/wiremock/mappings/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
{ | ||
"mappings": [ | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"url": "/test.git/HEAD" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"body": "ref: refs/heads/test\n", | ||
"headers": { | ||
"Content-Type": "application/x-git-advertisement" | ||
} | ||
} | ||
}, | ||
{ | ||
"request": { | ||
"method": "GET", | ||
"urlPattern": "/test.git/info/refs.*", | ||
"queryParameters": { | ||
"service": { | ||
"equalTo": "git-receive-pack" | ||
} | ||
} | ||
}, | ||
"response": { | ||
"status": 200, | ||
"body": "3e84c924d2574c95e8a7e8d7a76530b95d16f784\trefs/heads/test\n", | ||
"headers": { | ||
"Content-Type": "application/x-git-advertisement" | ||
} | ||
} | ||
}, | ||
{ | ||
"request": { | ||
"method": "POST", | ||
"url": "/test.git/git-receive-pack" | ||
}, | ||
"response": { | ||
"status": 200, | ||
"body": "0000ACK refs/heads/test\n0000", | ||
"headers": { | ||
"Content-Type": "application/x-git-receive-pack-result" | ||
} | ||
} | ||
} | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
apiVersion: v1 | ||
kind: Pod | ||
metadata: | ||
name: trestlebot-e2e-pod | ||
labels: | ||
app: trestlebot-e2e | ||
spec: | ||
containers: | ||
- name: mock-server-container | ||
image: localhost/mock-server:latest | ||
ports: | ||
- containerPort: 8080 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters