-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Align migration tool tests to new output directory structure #4561
Merged
Dwordcito
merged 2 commits into
master
from
dev-4560-update-migration-tool-system-tests-output-directory-structure
Sep 29, 2023
Merged
Align migration tool tests to new output directory structure #4561
Dwordcito
merged 2 commits into
master
from
dev-4560-update-migration-tool-system-tests-output-directory-structure
Sep 29, 2023
Conversation
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
jftuduri
requested review from
kevin-mcm,
sebasfalcone,
tsarquis88 and
Damian-Mangold
September 27, 2023 21:36
tsarquis88
approved these changes
Sep 28, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
# python3 -m pytest qa/tests/end_to_end/ --env dev
==================================================================================== test session starts =====================================================================================
platform linux -- Python 3.10.12, pytest-7.1.2, pluggy-1.3.0
rootdir: /home/platform-main/qa, configfile: pytest.ini
plugins: metadata-3.0.0, html-3.1.1, testinfra-5.0.0
collected 22 items
qa/tests/end_to_end/test_feed_ingestion/test_invalid_inputs.py .... [ 18%]
qa/tests/end_to_end/test_feed_ingestion/test_valid_inputs.py .................. [100%]
=============================================================================== 22 passed in 236.51s (0:03:56) ===============================================================================
% python3 qa/system_tests_launcher.py -k
SYSTEM-TESTS-LAUNCHER: [INFO] Creating the output folder at: /tmp/system_tests_results
SYSTEM-TESTS-LAUNCHER: [INFO] Building Docker image.
SYSTEM-TESTS-LAUNCHER: [INFO] Docker image built successfully.
SYSTEM-TESTS-LAUNCHER: [INFO] Running container that contains the pipeline script to be executed.
SYSTEM-TESTS-LAUNCHER: [INFO] Parameters for the pipeline: --env dev -k
->Step: SERVICES: Starting the services required by the tool.
->Step: SERVICES: Starting service -> mysql_migration_tool
->Step: SERVICES: The service mysql_migration_tool is running correctly.
->Step: BUILD: The build process was intended to be skipped, but the `build` folder does not exist.
->Step: BUILD: The build process began.
->Step: BUILD: The `build` folder has been created successfully.
->Step: BUILD: The tool has been compiled successfully.
->Step: BUILD: The executables and libraries have been built successfully.
->Step: INSTALLATION: Installing the built tool.
->Step: INSTALLATION: The tool was installed successfully.
->Step: TESTS: Running tests.
->Step: TESTS: The tests have passed. Results: 22 passed in 247.88s (0:04:07)
SYSTEM-TESTS-LAUNCHER: [INFO] Pipeline execution finished. Results in: /tmp/system_tests_results
SYSTEM-TESTS-LAUNCHER: [INFO] Removing container.
SYSTEM-TESTS-LAUNCHER: [INFO] The Docker container called `intelligence-system-tests` was removed.
% cat /tmp/system_tests_results/system_tests_results.txt
============================= test session starts ==============================
platform linux -- Python 3.10.12, pytest-7.1.2, pluggy-1.3.0
rootdir: /source/qa, configfile: pytest.ini
plugins: metadata-3.0.0, html-3.1.1, testinfra-5.0.0
collected 22 items
tests/end_to_end/test_feed_ingestion/test_invalid_inputs.py .... [ 18%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py .............. [ 81%]
.... [100%]
--------- generated html file: file:///output/system_tests_report.html ---------
======================== 22 passed in 247.88s (0:04:07) ========================
Damian-Mangold
approved these changes
Sep 28, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM !
kevin-mcm
approved these changes
Sep 28, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
> python3 -m pytest -vvv tests/end_to_end/ --html=e2e-report.html --self-contained-html
============================================================================================== test session starts ==============================================================================================
platform linux -- Python 3.10.12, pytest-7.1.2, pluggy-1.3.0 -- /usr/bin/python3
cachedir: .pytest_cache
metadata: {'Python': '3.10.12', 'Platform': 'Linux-5.15.0-84-generic-x86_64-with-glibc2.35', 'Packages': {'pytest': '7.1.2', 'pluggy': '1.3.0'}, 'Plugins': {'html': '3.1.1', 'testinfra': '5.0.0', 'metadata': '3.0.0'}}
rootdir: /home/server/intelligence-platform/qa, configfile: pytest.ini
plugins: html-3.1.1, testinfra-5.0.0, metadata-3.0.0
collected 22 items
tests/end_to_end/test_feed_ingestion/test_invalid_inputs.py::test_invalid_inputs[EMPTY_FEED] PASSED [ 4%]
tests/end_to_end/test_feed_ingestion/test_invalid_inputs.py::test_invalid_inputs[NOT_SUPPORTED_FORMAT_FEED] PASSED [ 9%]
tests/end_to_end/test_feed_ingestion/test_invalid_inputs.py::test_invalid_inputs[INVALID_JSON_FEED] PASSED [ 13%]
tests/end_to_end/test_feed_ingestion/test_invalid_inputs.py::test_invalid_inputs[INVALID_XML_FEED] PASSED [ 18%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[ALAS1_FEED] PASSED [ 22%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[ALAS2_FEED] PASSED [ 27%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[ALAS2022_FEED] PASSED [ 31%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[ALAS2023_FEED] PASSED [ 36%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[ARCH_LINUX_FEED] PASSED [ 40%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[DEBIAN_FEED] PASSED [ 45%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[NVD_FEED] PASSED [ 50%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[REDHAT_FEED] PASSED [ 54%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[SUSE_FEED] PASSED [ 59%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[ALMALINUX_FEED] PASSED [ 63%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_complete_migration[CANONICAL_FEED] PASSED [ 68%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_insertion_and_update_delta[ARCH_VULNERABILITY_ADDED] PASSED [ 72%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_insertion_and_update_delta[ARCH_VULNERABILITY_UPDATED] PASSED [ 77%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_delta_schema[ARCH_DELTA_INSERT_SCHEMA_VALIDATION] PASSED [ 81%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_delta_schema[ARCH_DELTA_UPDATE_SCHEMA_VALIDATION] PASSED [ 86%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_delta_schema[ARCH_DELTA_DELETE_SCHEMA_VALIDATION] PASSED [ 90%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_elimination_delta[ARCH_VULNERABILITY_REMOVED] PASSED [ 95%]
tests/end_to_end/test_feed_ingestion/test_valid_inputs.py::test_skip_migration[SKIP_MIGRATION_PROCESS] PASSED [100%]
--------------------------------------------------------------- generated html file: file:///home/server/intelligence-platform/qa/e2e-report.html ---------------------------------------------------------------
======================================================================================== 22 passed in 109.91s (0:01:49) =========================================================================================
> python3 qa/system_tests_launcher.py
SYSTEM-TESTS-LAUNCHER: [INFO] Creating the output folder at: /tmp/system_tests_results
SYSTEM-TESTS-LAUNCHER: [INFO] Building Docker image.
SYSTEM-TESTS-LAUNCHER: [INFO] Docker image built successfully.
SYSTEM-TESTS-LAUNCHER: [INFO] Running container that contains the pipeline script to be executed.
SYSTEM-TESTS-LAUNCHER: [INFO] Parameters for the pipeline: --env dev
SYSTEM-TESTS-LAUNCHER: [INFO] Removing the build directory in order to build the system from scratch.
SYSTEM-TESTS-LAUNCHER: [INFO] The '/home/server/intelligence-platform/build' directory was removed.
->Step: SERVICES: Starting the services required by the tool.
->Step: SERVICES: Starting service -> mysql_migration_tool
->Step: SERVICES: The service mysql_migration_tool is running correctly.
->Step: BUILD: The build process began.
->Step: BUILD: The `build` folder has been created successfully.
->Step: BUILD: The tool has been compiled successfully.
->Step: BUILD: The executables and libraries have been built successfully.
->Step: INSTALLATION: Installing the built tool.
->Step: INSTALLATION: The tool was installed successfully.
->Step: TESTS: Running tests.
->Step: TESTS: The tests have passed. Results: 22 passed in 146.24s (0:02:26)
SYSTEM-TESTS-LAUNCHER: [INFO] Pipeline execution finished. Results in: /tmp/system_tests_results
SYSTEM-TESTS-LAUNCHER: [INFO] Removing container.
SYSTEM-TESTS-LAUNCHER: [INFO] The Docker container called `intelligence-system-tests` was removed.
Dwordcito
deleted the
dev-4560-update-migration-tool-system-tests-output-directory-structure
branch
September 29, 2023 15:06
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR updates the system test of the migration tool by aligning the test's expected output files to the tool's new output directory structure.
Testing performed
System tests work correctly
System Tests Pipeline (Docker) works correctly