Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
backend_api
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Package registry
Container registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
videoag
backend_api
Commits
bae2a04e
Commit
bae2a04e
authored
May 23, 2024
by
Simon Künzel
Browse files
Options
Downloads
Patches
Plain Diff
Fix failing test not actually failing and add artifacts (This commit should fail), Closes
#24
parent
a75cf5a8
No related branches found
No related tags found
No related merge requests found
Pipeline
#5874
canceled
May 23, 2024
Stage: build
Stage: test
Changes
3
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+5
-1
5 additions, 1 deletion
.gitlab-ci.yml
docker_start.sh
+8
-4
8 additions, 4 deletions
docker_start.sh
tests/routes/site.py
+1
-1
1 addition, 1 deletion
tests/routes/site.py
with
14 additions
and
6 deletions
.gitlab-ci.yml
+
5
−
1
View file @
bae2a04e
...
@@ -30,3 +30,7 @@ run-tests:
...
@@ -30,3 +30,7 @@ run-tests:
entrypoint
:
[
"
"
]
entrypoint
:
[
"
"
]
script
:
script
:
-
$CI_PROJECT_DIR/docker_start.sh -test
-
$CI_PROJECT_DIR/docker_start.sh -test
artifacts
:
paths
:
-
$CI_PROJECT_DIR/coverage/report.txt
-
$CI_PROJECT_DIR/coverage/html/*
This diff is collapsed.
Click to expand it.
docker_start.sh
+
8
−
4
View file @
bae2a04e
...
@@ -11,10 +11,14 @@ if [ $# = 1 ] && [ $1 = "-test" ]; then
...
@@ -11,10 +11,14 @@ if [ $# = 1 ] && [ $1 = "-test" ]; then
uname
-a
uname
-a
export
VIDEOAG_API_TEST_CONFIG_OVERRIDE
=
"../config/test_config_override.py"
export
VIDEOAG_API_TEST_CONFIG_OVERRIDE
=
"../config/test_config_override.py"
python3
-V
python3
-V
python3
-m
coverage run
--data-file
"../coverage/.data"
run_tests.py
python3
-m
coverage run
--data-file
"../coverage/.data"
run_tests.py
||
python3
-m
coverage report
--data-file
"../coverage/.data"
--include
"./*"
{
echo
"Test failed!"
;
exit
1
;
}
python3
-m
coverage report
--data-file
"../coverage/.data"
-m
--include
"./*"
>
../coverage/report.txt
python3
-m
coverage report
--data-file
"../coverage/.data"
--include
"./*"
||
python3
-m
coverage html
-d
"../coverage/html/"
--data-file
"../coverage/.data"
--include
"./*"
{
echo
"Coverage report stdout failed"
;
exit
1
;
}
python3
-m
coverage report
--data-file
"../coverage/.data"
-m
--include
"./*"
>
../coverage/report.txt
||
{
echo
"Coverage report report.txt failed"
;
exit
1
;
}
python3
-m
coverage html
-d
"../coverage/html/"
--data-file
"../coverage/.data"
--include
"./*"
||
{
echo
"Coverage report html failed"
;
exit
1
;
}
else
else
echo
"Running nginx and uWSGI"
echo
"Running nginx and uWSGI"
nginx
-c
${
VIDEOAG_NGINX_CONFIG
}
-p
.
&
nginx
-c
${
VIDEOAG_NGINX_CONFIG
}
-p
.
&
...
...
This diff is collapsed.
Click to expand it.
tests/routes/site.py
+
1
−
1
View file @
bae2a04e
...
@@ -8,7 +8,7 @@ class SiteTest(ApiTest):
...
@@ -8,7 +8,7 @@ class SiteTest(ApiTest):
# TODO test live config
# TODO test live config
self
.
do_json_request
(
self
.
do_json_request
(
"
GET
"
,
"
GET
"
,
"
/
status
"
,
"
/
path-which-does-not-exist
"
,
None
,
None
,
{
{
"
status
"
:
"
available
"
,
"
status
"
:
"
available
"
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment