Commit 0b8ef09a authored by Spiros Koulouzis's avatar Spiros Koulouzis

added python code in travis test/build/docker

parent af86bc77
......@@ -3,23 +3,48 @@ services:
- docker
matrix:
include:
#------------sure_tosca-server-----------------
- language: python
python: 3.7
before_script:
- cd sure_tosca-flask-server
- pip install -r requirements.txt
- pip install -r test-requirements.txt
script:
- python -m unittest discover
- docker build -t alogo53/sure-tosca:3.0.0 .
#------------sure_tosca-client-----------------
- language: python
python: 3.8
before_script:
- cd planner
- cd sure_tosca-client_python_stubs
- pip install -r requirements.txt
- pip install -r test-requirements.txt
script:
- python -m unittest discover
- docker build -t alogo53/planner:3.0.0 .
#------------semaphore-client------------------
- language: python
python: 3.7
python: 3.8
before_script:
- cd sure_tosca-flask-server
- cd semaphore-python-client-generated
- pip install -r requirements.txt
- pip install -r test-requirements.txt
script:
- python -m unittest discover
- docker build -t alogo53/sure-tosca:3.0.0 .
#------------planner------------------
- language: python
python: 3.8
before_script:
- cd planner
- pip install -r requirements.txt
script:
- python -m unittest discover
- docker build -t alogo53/planner:3.0.0 .
#------------deployer------------------
- language: python
python: 3.8
before_script:
......@@ -28,6 +53,8 @@ matrix:
script:
- python -m unittest discover
- docker build -t alogo53/deployer:3.0.0 .
#------------manager and provisioner------------------
- language: java
jdk: openjdk11
before_script:
......@@ -38,6 +65,9 @@ matrix:
- mvn -Dmaven.test.skip=true dockerfile:build
- cd ../provisioner
- mvn -Dmaven.test.skip=true dockerfile:build
after_success:
- docker stack deploy conf -c docker-compose.yml
- count=0 && until $(curl --output /dev/null --silent --head --fail http://localhost:8081);
......
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class
# C extensions
*.so
# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
*.egg-info/
.installed.cfg
*.egg
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec
# Installer logs
pip-log.txt
pip-delete-this-directory.txt
# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*,cover
.hypothesis/
venv/
.python-version
# Translations
*.mo
*.pot
# Django stuff:
*.log
# Sphinx documentation
docs/_build/
# PyBuilder
target/
#Ipython Notebook
.ipynb_checkpoints
# Default ignored files
/workspace.xml
\ No newline at end of file
<component name="InspectionProjectProfileManager">
<settings>
<option name="USE_PROJECT_PROFILE" value="false" />
<version value="1.0" />
</settings>
</component>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.8" project-jdk-type="Python SDK" />
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/polemarch-python-client-generated.iml" filepath="$PROJECT_DIR$/.idea/polemarch-python-client-generated.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
<component name="PyDocumentationSettings">
<option name="format" value="PLAIN" />
<option name="myDocStringFormat" value="Plain" />
</component>
</module>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/.." vcs="Git" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ChangeListManager">
<list default="true" id="9453a48d-0d13-4782-8a8a-4af9ab871dbf" name="Default Changelist" comment="">
<change afterPath="$PROJECT_DIR$/../deployer/service/polemarch_helper.py" afterDir="false" />
<change afterPath="$PROJECT_DIR$/.idea/.gitignore" afterDir="false" />
<change afterPath="$PROJECT_DIR$/.idea/inspectionProfiles/profiles_settings.xml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/.idea/misc.xml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/.idea/modules.xml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/.idea/polemarch-python-client-generated.iml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/.idea/vcs.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../deployer/service/ansible_service.py" beforeDir="false" afterPath="$PROJECT_DIR$/../deployer/service/ansible_service.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../deployer/service/deploy_service.py" beforeDir="false" afterPath="$PROJECT_DIR$/../deployer/service/deploy_service.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../deployer/service/tosca_helper.py" beforeDir="false" afterPath="$PROJECT_DIR$/../deployer/service/tosca_helper.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../deployer/test-requirements.txt" beforeDir="false" afterPath="$PROJECT_DIR$/../deployer/test-requirements.txt" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../deployer/test/test_deployer.py" beforeDir="false" afterPath="$PROJECT_DIR$/../deployer/test/test_deployer.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../docker-compose.yml" beforeDir="false" afterPath="$PROJECT_DIR$/../docker-compose.yml" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
<option name="LAST_RESOLUTION" value="IGNORE" />
</component>
<component name="Git.Settings">
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$/.." />
</component>
<component name="IgnoredFileRootStore">
<option name="generatedRoots">
<set>
<option value="$PROJECT_DIR$/.idea" />
</set>
</option>
</component>
<component name="ProjectId" id="1ZlM2Ozq3wWdNnN5v2KalFhkmvL" />
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
<component name="ProjectViewState">
<option name="hideEmptyMiddlePackages" value="true" />
<option name="showExcludedFiles" value="true" />
<option name="showLibraryContents" value="true" />
</component>
<component name="PropertiesComponent">
<property name="RunOnceActivity.ShowReadmeOnStart" value="true" />
<property name="last_opened_file_path" value="$PROJECT_DIR$" />
</component>
<component name="SvnConfiguration">
<configuration />
</component>
<component name="TaskManager">
<task active="true" id="Default" summary="Default task">
<changelist id="9453a48d-0d13-4782-8a8a-4af9ab871dbf" name="Default Changelist" comment="" />
<created>1585409019931</created>
<option name="number" value="Default" />
<option name="presentableId" value="Default" />
<updated>1585409019931</updated>
</task>
<servers />
</component>
<component name="WindowStateProjectService">
<state x="467" y="190" width="1053" height="732" key="find.popup" timestamp="1585418292797">
<screen x="67" y="34" width="1853" height="1046" />
</state>
<state x="467" y="190" width="1053" height="732" key="find.popup/67.34.1853.1046@67.34.1853.1046" timestamp="1585418292797" />
</component>
</project>
\ No newline at end of file
# Swagger Codegen Ignore
# Generated by swagger-codegen https://github.com/swagger-api/swagger-codegen
# Use this file to prevent files from being overwritten by the generator.
# The patterns follow closely to .gitignore or .dockerignore.
# As an example, the C# client generator defines ApiClient.cs.
# You can make changes and tell Swagger Codgen to ignore just this file by uncommenting the following line:
#ApiClient.cs
# You can match any string of characters against a directory, file or extension with a single asterisk (*):
#foo/*/qux
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux
# You can recursively match patterns against a directory, file or extension with a double asterisk (**):
#foo/**/qux
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux
# You can also negate patterns with an exclamation (!).
# For example, you can ignore all files in a docs folder with the file extension .md:
#docs/*.md
# Then explicitly reverse the ignore rule for a single file:
#!docs/README.md
# ref: https://docs.travis-ci.com/user/languages/python
language: python
python:
- "2.7"
- "3.2"
- "3.3"
- "3.4"
- "3.5"
#- "3.5-dev" # 3.5 development branch
#- "nightly" # points to the latest development branch e.g. 3.6-dev
# command to install dependencies
install: "pip install -r requirements.txt"
# command to run tests
script: nosetests
This diff is collapsed.
......@@ -131,8 +131,8 @@ class CreateUser(object):
raise ValueError("Invalid value for `username`, length must be less than or equal to `150`") # noqa: E501
if username is not None and len(username) < 1:
raise ValueError("Invalid value for `username`, length must be greater than or equal to `1`") # noqa: E501
if username is not None: # and not re.search(r'^[\\w.@+-]+$', username): # noqa: E501
raise ValueError(r"Invalid value for `username`, must be a follow pattern or equal to `/^[\\w.@+-]+$/`") # noqa: E501
# if username is not None: # and not re.search(r'^[\\w.@+-]+$', username): # noqa: E501
# raise ValueError(r"Invalid value for `username`, must be a follow pattern or equal to `/^[\\w.@+-]+$/`") # noqa: E501
self._username = username
......
......@@ -118,8 +118,8 @@ class OneUser(object):
raise ValueError("Invalid value for `username`, length must be less than or equal to `150`") # noqa: E501
if username is not None and len(username) < 1:
raise ValueError("Invalid value for `username`, length must be greater than or equal to `1`") # noqa: E501
if username is not None: # and not re.search(r'^[\\w.@+-]+$', username): # noqa: E501
raise ValueError(r"Invalid value for `username`, must be a follow pattern or equal to `/^[\\w.@+-]+$/`") # noqa: E501
# if username is not None: # and not re.search(r'^[\\w.@+-]+$', username): # noqa: E501
# raise ValueError(r"Invalid value for `username`, must be a follow pattern or equal to `/^[\\w.@+-]+$/`") # noqa: E501
self._username = username
......
......@@ -108,8 +108,8 @@ class User(object):
raise ValueError("Invalid value for `username`, length must be less than or equal to `150`") # noqa: E501
if username is not None and len(username) < 1:
raise ValueError("Invalid value for `username`, length must be greater than or equal to `1`") # noqa: E501
if username is not None: # and not re.search(r'^[\\w.@+-]+$', username): # noqa: E501
raise ValueError(r"Invalid value for `username`, must be a follow pattern or equal to `/^[\\w.@+-]+$/`") # noqa: E501
# if username is not None: # and not re.search(r'^[\\w.@+-]+$', username): # noqa: E501
# raise ValueError(r"Invalid value for `username`, must be a follow pattern or equal to `/^[\\w.@+-]+$/`") # noqa: E501
self._username = username
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment