Skip to content

Latest commit

 

History

History
61 lines (41 loc) · 2.66 KB

README.md

File metadata and controls

61 lines (41 loc) · 2.66 KB

Integration Tests

Aerie-CLI integration tests exercise commands against an actual instance of Aerie.

WARNING

These tests will delete and modify data permanently. Expect the localhost instance of Aerie to be modified heavily. These test will delete all models.

See: localhost configuration

Running Locally

To set up a local test environment, use the test environment and docker-compose files in the root of the repo:

docker compose -f docker-compose-test.yml up

Invoke the tests using pytest from the tests/integration_tests directory:

python3 -m pytest .

Updating Tests for New Aerie Versions

Integration tests are automatically run by CI against all supported Aerie versions. To add and test support for a new Aerie version:

  1. Download the appropriate version release JAR for the Banananation model and add it to tests/integration_tests/models, named as banananation-X.X.X.jar (substituting the correct version number).
  2. Update the .env file DOCKER_TAG value to the new version string. This defaults the local deployment to the latest Aerie version.
  3. Update docker-compose-test.yml as necessary to match the new Aerie version. The aerie-ui compose file can be a helpful reference to identify changes.
  4. Manually run the integration tests and update the code and tests as necessary for any Aerie changes.
  5. Update the aerie-version list in the CI configuration to include the new version.
  6. If breaking changes are necessary to support the new Aerie version, remove any Aerie versions which are no longer supported from the CI configuration and remove the corresponding banananation JAR file.
  7. Open a PR and verify all tests still pass.

Summary of Integration Tests

  • Configuration initialization is in conftest.py to ensure all tests use localhost
  • These tests will end with the localhost configuration active
  • Test all configurations commands
  • Test all models commands
  • Test all plans commands
  • Tests simulations and plans download... commands as well
  • Test all scheduling commands
  • Test all expansion commands
  • Test all metadata commands
  • Test all constraints commands