Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
SMART
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
3
Issues
3
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
UNI-KLU
SMART
Commits
8843dcb6
Commit
8843dcb6
authored
Feb 11, 2020
by
Alexander
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
push Docker image only if build was successful
parent
f7a072d8
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
9 deletions
+11
-9
build.py
bin/build.py
+8
-6
test_cluster.py
...ommunity-detection-microservice/app/tests/test_cluster.py
+2
-2
test_clusterer.py
...munity-detection-microservice/app/tests/test_clusterer.py
+1
-1
No files found.
bin/build.py
View file @
8843dcb6
...
...
@@ -35,16 +35,18 @@ for command_arg in command_args:
os
.
remove
(
os
.
path
.
join
(
ROOT
,
DOCKER_COMPOSE_NAME
))
res_str
.
append
(
f
"{image_name} built with exit code {exit_val}"
)
if
exit_val
!=
0
:
error
=
exit_val
# push created Docker image
exit_val
=
os
.
system
(
f
"docker push {image_name}"
)
res_str
.
append
(
f
"{image_name} pushed with exit code {exit_val}"
)
if
exit_val
!=
0
:
error
=
exit_val
else
:
# push created Docker image
exit_val
=
os
.
system
(
f
"docker push {image_name}"
)
res_str
.
append
(
f
"{image_name} pushed with exit code {exit_val}"
)
if
exit_val
!=
0
:
error
=
exit_val
print
(
f
"Found {len(command_args)} images"
)
for
s
in
res_str
:
...
...
src/data-hub/community-detection-microservice/app/tests/test_cluster.py
View file @
8843dcb6
import
unittest
import
sys
sys
.
path
.
insert
(
1
,
'./'
)
sys
.
path
.
insert
(
1
,
'.
.
/'
)
# python -m unittest discover
-v tests
# python -m unittest discover
from
db.entities.cluster
import
Cluster
from
db.entities
import
TimeCluster
,
LocationCluster
...
...
src/data-hub/community-detection-microservice/app/tests/test_clusterer.py
View file @
8843dcb6
...
...
@@ -2,7 +2,7 @@ import unittest
import
sys
sys
.
path
.
insert
(
1
,
'../'
)
# python -m unittest discover
-v tests
# python -m unittest discover
from
processing.clusterer
import
Clusterer
class
TestClusterer
(
unittest
.
TestCase
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment