Commit Graph

663 Commits (5bee66fc5d2514fb2000bb8adffe84de94516964)

Author SHA1 Message Date
Matt Clay 5bee66fc5d
ansible-test - More type hint updates. (#78455)
* Simple regex replace of multi-line function arg annotations on the first line.

* Manually fix up ArgumentParser type annotations.

* Manual type hint conversions.

* Manual conversion of function type hints.

* Remove unnecessary type hints on for statements.
2 years ago
Matt Clay b993b5cd49
ansible-test - Convert more type hints. (#78449)
* Simple regex replace of multi-line function arg annotations.

* Simple regex replace of multi-line function arg annotations with default values.

* Simple regex replace of multi-line function arg return annotations.

* Simple regex replace of assignment annotations.
2 years ago
Matt Clay 02e98810a9
Re-organize CI test groups for POSIX tests. (#77420)
* `context/target` tests must be in groups 1 - 2.
* `context/controller` tests must be in groups 3 - 5.

This makes it easier to efficiently organize groups and balance test runtimes.
2 years ago
Matt Clay 3eb0485dd9
ansible-test - Use more native type hints. (#78435)
* ansible-test - Use more native type hints.

Simple search and replace to switch from comments to native type hints for return types of functions with no arguments.

* ansible-test - Use more native type hints.

Conversion of simple single-line function annotation type comments to native type hints.

* ansible-test - Use more native type hints.

Conversion of single-line function annotation type comments with default values to native type hints.

* ansible-test - Use more native type hints.

Manual conversion of type annotation comments for functions which have pylint directives.
2 years ago
Matt Clay f2abfc4b3d
ansible-test - Parse content config only once. (#78418) 2 years ago
Matt Clay d8fefba20e
ansible-test - Update locale logic to match core. (#78389)
Now that core requires UTF-8 filesystem encoding, ansible-test does as well.

Additionally, the `en_US.UTF-8` or `C.UTF-8` encoding must be available.
Previously the `en_US.UTF-8` encoding was requested, but its availability was never verified.
The fallback to `C.UTF-8` maintains UTF-8 encoding while allowing more flexibility in the running environment.
2 years ago
Matt Clay b0b58fa7c2
ansible-test - Update base and default containers. (#78377) 2 years ago
Matt Clay a3c90dd0bc
ansible-test - Fix TTY and output handling. (#78350) 2 years ago
Matt Clay 0012263c7a
ansible-test - Fix handling of args after `--` (#78328) 2 years ago
Matt Clay 61af59c808
ansible-test - Update distro containers to 4.4.0. (#78322) 2 years ago
Matt Clay 4cd3425dfe
ansible-test - Update coverage to 6.4.2 (#78320) 2 years ago
Matt Clay 90ef914f77
ansible-test - Drop Python 3.8 controller support. (#78237) 2 years ago
Matt Clay f3f4ad9332
ansible-test - Use sudo for all remotes. (#78310) 2 years ago
Matt Clay 8565deaae3
ansible-test - Install `acl` on Alpine remotes. (#78303) 2 years ago
Matt Clay 8bb20fe06b
ansible-test - Enable ACL support on more remotes. (#78299) 2 years ago
Matt Clay b63812bc08 ansible-test - Enable ACLs on FreeBSD remotes.
This allows integration tests to switch from one unprivileged user
to another, sharing files between the users using ACLs.
2 years ago
Jordan Borean 75de4a37bc
validate-modules - allow raw module return type (#78231) 2 years ago
Matt Clay b9d13d222c ansible-test - Improve pip bootstrap download. 2 years ago
Sviatoslav Sydorenko e481b35e23
Delete core-ci `query` param from ansible-test (#78136)
Ref: https://github.com/ansible/ansible-core-ci/pull/343
2 years ago
Matt Clay ca04dc28a2 ansible-test - Remove deprecated test platforms. 2 years ago
Matt Clay cf9fd2d7da ansible-test - Use shlex.join where appropriate. 2 years ago
Matt Clay 24d91f552c ansible-test - Add support for more remotes. 2 years ago
Matt Clay 5666c6d6a3 ansible-test - More flexible become support. 2 years ago
Don Naro 3cd2c494bd
issue #72449 winrm script rm (#77931) 2 years ago
Matt Clay 2f0530396b ansible-test - Clean up type hints and comments. 2 years ago
Matt Clay a4e4413cde ansible-test - Update distro containers to 4.3.0.
The primary change in this update is removal of `/etc/ansible/hosts` from the containers.
2 years ago
Matt Clay 5b3557f8ba ansible-test - Allow docstring in docs-only module 2 years ago
Matt Clay c2b36ba04d ansible-test - Update base and default containers. 2 years ago
Matt Clay 23914d3f0b
ansible-test - Adjust unit test mock usage. (#77961) 2 years ago
Sloane Hertel e89176caac
Pin PyYAML version compatible with Python 3.8+ (#77936)
Co-authored-by: Brian Coca <bcoca@users.noreply.github.com>
Co-authored-by: Matt Clay <matt@mystile.com>
2 years ago
Sloane Hertel 143e7fb45e
ansible-galaxy - support resolvelib versions >= 0.5.3, < 0.9.0 (#77649)
* ansible-galaxy - support resolvelib versions >= 0.5.3, <= 0.8.1

Test incompatibilities are removed for resolvelib >= 0.6.0

Test against the latest 0.8.x version and fix requirements

* Fix tests - use a venv for testing the range of resolvelib versions

* Update temporary hardcoded fallback for ansible-test

* Update hardcoded upperbound for sanity tests

* Make error check more flexible
2 years ago
Matt Clay df765c0ecf ansible-test - Update Alpine, openSUSE containers 2 years ago
Matt Clay 52c8613a04 ansible-test - Skip mypy runs under Python 3.11. 2 years ago
Matt Clay 11b6032e73 ansible-test - Ignore vendored code in mypy test. 2 years ago
Matt Clay 81351022d8 ansible-test - Prefer unittest.mock for core. 2 years ago
Matt Clay f933314101 ansible-test - Fix shell target options handling. 2 years ago
Matt Clay 86779cc903 ansible-test - Code cleanup.
This helps prepare for a future pylint upgrade.
2 years ago
Matt Clay 289cba333b ansible-test - More multi-arch containers. 2 years ago
Matt Clay 13d03c3c22
ansible-test - Add RHEL 9 / FreeBSD 13.1 remotes. (#77851) 2 years ago
Matt Clay 3d2c2e60aa
ansible-test - Update distro containers. (#77847)
* ansible-test - Add a Ubuntu 22.04 container.
* ansible-test - Add a Fedora 36 container.
* ansible-test - Update distro containers.
* Fix dnf test on Fedora 36.
* Work around scp test issues.
2 years ago
Matt Clay 76ead1e768 ansible-test - Fix remote args restriction.
The platform-specific and global fallbacks were not working with the `--remote` option.

This regression was introduced by https://github.com/ansible/ansible/pull/77711
2 years ago
Matt Clay 185340e667 ansible-test - Update default containers.
These containers include Python 3.11 sanity test environments.
2 years ago
Matt Clay dfde4be444 Add Python 3.11 support.
ci_complete
ci_coverage
2 years ago
Matt Clay 9600e3064a
ansible-test - Improve requirements handling. (#77825)
The requirements for virtualenv and coverage are now kept in a requirements file for easier container builds.

The test-constraints sanity test has been updated to make sure the requirements file is kept up-to-date.
2 years ago
Matt Clay 290fb5e0ca
ansible-test - Upgrade to coverage 6.3.3. (#77817) 2 years ago
Matt Clay 1e3cf9f732
ansible-test - Make distro containers multi-arch. (#77814) 2 years ago
Matt Clay 449d82a521 ansible-test - Add RHEL 8.6 support. 2 years ago
Matt Clay fe349a1ccd
ansible-test - Enhance the shell command. (#77734)
* ansible-test - Add shell --export option.

* ansible-test - Support cmd args for shell command.

Also allow shell to be used without a valid layout if no delegation is required.

* ansible-test - Improve stderr/stdout consistency.

By default all output goes to stdout only, with the exception of a fatal error.

When using any of the following, all output defaults to stderr instead:

* sanity with the `--lint` option -- sanity messages to stdout
* coverage analyze -- output to stdout if the output file is `/dev/stdout`
* shell -- shell output to stdout

This fixes issues two main issues:

* Unpredictable output order when using both info and error/warning messages.
* Mixing of lint/command/shell output with bootstrapping messages on stdout.

* ansible-test - Add changelog fragment.
2 years ago
Matt Clay cc5ac88c4c Update mypy test. Fix type hints for Python 3.9.
This also bumps the minimum controller version (for mypy only) to Python 3.9.
2 years ago
Matt Clay 2cc74b04c4 ansible-test - Add multi-arch remote support. 2 years ago