-
Notifications
You must be signed in to change notification settings - Fork 342
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
import tox.ini much faster than the other tests (less than 5 minutes), we don't need to build the collection first or to pull the ansible-test container works from anyway, no need to copy the collection in .ansible/collections/ansible_collections/amazon/aws first generate HTML coverage, e.g: https://c8cca5e7f93c66c3bfca-5f43057c94d0562db863016349fecb6f.ssl.cf5.rackcdn.com/1090/f1142b4b561938403637af89bfe76169da025d75/check/cloud-tox-py39/562db5d/docs/coverage/index.html test with py39 currently, but we can extend the matrix adjustment to properly reset some global variables. The problem doesn't happen with ansible-test because the tests are run in parallel and thus, there is no shared memory space. Reviewed-by: Mark Chappell <None>
- Loading branch information
Showing
3 changed files
with
30 additions
and
0 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 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 |
---|---|---|
|
@@ -9,6 +9,7 @@ | |
from pprint import pprint | ||
import pytest | ||
import json | ||
import warnings | ||
|
||
try: | ||
import botocore | ||
|
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,20 @@ | ||
[tox] | ||
skipsdist=True | ||
envlist = clean,ansible{2.12,2.13}-py{38,39,310}-{with_constraints,without_constraints} | ||
|
||
[testenv] | ||
deps = | ||
pytest | ||
pytest-cov | ||
ansible2.12: ansible-core>2.12,<2.13 | ||
ansible2.13: ansible-core>2.13,<2.14 | ||
!ansible2.12-!ansible2.13: ansible-core | ||
pytest-ansible-units | ||
-rtest-requirements.txt | ||
with_constraints: -rtests/unit/constraints.txt | ||
commands = pytest --cov-report html --cov plugins {posargs:tests/} | ||
|
||
[testenv:clean] | ||
deps = coverage | ||
skip_install = true | ||
commands = coverage erase |