fcd0790c03
Instead of using string manipulation and hardcoded path separators, use the os.path.join method for better consistency. Add some initial pytest unit tests. Tests include one to verify the generator can create a fluxcd application. Apply flake8 corrections to entire codebase. Apply pylint corrections to entire codebase. Diabled bandit. Update tox.ini file and test-requirements.txt Make updates to .zuul.yaml to enable coverage tests with helm. Coverage check will fail if coverage falls below 55% for now. Zuul is using the same version of helm as is current in STX; v3.12.2. TODO - Make sure flake8, pylint, etc.. are good. Test Plan: PASS - Verify the generator can still build an example fluxcd app TODO - Verify the generator can still buld an example armada app Story: 2010937 Task: 48918 Task: 48917 Change-Id: I18a52cd98b730cc96b2b51cd4c1ab16785ad9857 Signed-off-by: Reed, Joshua <Joshua.Reed@windriver.com>
80 lines
1.6 KiB
YAML
80 lines
1.6 KiB
YAML
---
|
|
- project:
|
|
vars:
|
|
ensure_tox_version: '<4'
|
|
check:
|
|
jobs:
|
|
- app-gen-tool-tox-py39
|
|
- app-gen-tool-tox-flake8
|
|
- app-gen-tool-tox-pylint
|
|
- app-gen-tool-tox-coverage
|
|
gate:
|
|
jobs:
|
|
- app-gen-tool-tox-py39
|
|
- app-gen-tool-tox-flake8
|
|
- app-gen-tool-tox-pylint
|
|
- app-gen-tool-tox-coverage
|
|
|
|
- job:
|
|
name: app-gen-tool-tox-py39
|
|
parent: tox-py39
|
|
description: |
|
|
Run py39 test for app-gen-tool
|
|
nodeset: debian-bullseye
|
|
files:
|
|
- ./*
|
|
vars:
|
|
tox_envlist: py39
|
|
python_version: 3.9
|
|
tox_extra_args: -c tox.ini
|
|
|
|
- job:
|
|
name: app-gen-tool-tox-coverage
|
|
parent: tox-py39
|
|
description: |
|
|
Run coverage test for app-gen-tool
|
|
nodeset: debian-bullseye
|
|
pre-run: playbooks/app-gen-tool-tox-coverage/pre.yaml
|
|
files:
|
|
- ./*
|
|
vars:
|
|
tox_envlist: coverage
|
|
python_version: 3.9
|
|
tox_extra_args: -c tox.ini
|
|
|
|
- job:
|
|
name: app-gen-tool-tox-flake8
|
|
parent: tox
|
|
description: |
|
|
Run flake8 test for app-gen-tool
|
|
nodeset: debian-bullseye
|
|
files:
|
|
- ./*
|
|
vars:
|
|
tox_envlist: flake8
|
|
tox_extra_args: -c tox.ini
|
|
|
|
- job:
|
|
name: app-gen-tool-tox-pylint
|
|
parent: tox
|
|
description: |
|
|
Run pylint test for app-gen-tool
|
|
nodeset: debian-bullseye
|
|
files:
|
|
- ./*
|
|
vars:
|
|
tox_envlist: pylint
|
|
tox_extra_args: -c tox.ini
|
|
|
|
- job:
|
|
name: app-gen-tool-tox-bandit
|
|
parent: tox
|
|
description: |
|
|
Run bandit test for app-gen-tool
|
|
nodeset: debian-bullseye
|
|
files:
|
|
- ./*
|
|
vars:
|
|
tox_envlist: bandit
|
|
tox_extra_args: -c tox.ini
|