-
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
Update known flaws files #4443
Update known flaws files #4443
Conversation
21e5b07
to
cd849fe
Compare
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.
I'm getting an error:
$ pip3 freeze | grep wazuh-testing
wazuh-testing @ file:///home/selu/Git/qa-integration-framework
$
$ pytest tests/scans/code_analysis/test_python_flaws.py --disable-warnings --exclude_directories tests,test --reference master
============================================================================================ test session starts =============================================================================================
platform linux -- Python 3.10.12, pytest-7.1.2, pluggy-0.13.1
rootdir: /home/selu/Git/wazuh-qa/tests, configfile: pytest.ini
plugins: html-3.1.1, testinfra-5.0.0, tavern-2.0.2, metadata-2.0.4
collected 0 items / 1 error
=================================================================================================== ERRORS ===================================================================================================
_________________________________________________________________________ ERROR collecting scans/code_analysis/test_python_flaws.py __________________________________________________________________________
ImportError while importing test module '/home/selu/Git/wazuh-qa/tests/scans/code_analysis/test_python_flaws.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib/python3.10/importlib/__init__.py:126: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
tests/scans/code_analysis/test_python_flaws.py:4: in <module>
from wazuh_testing.tools.scans.code_analysis import \
E ModuleNotFoundError: No module named 'wazuh_testing.tools.scans'
========================================================================================== short test summary info ===========================================================================================
ERROR tests/scans/code_analysis/test_python_flaws.py
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
============================================================================================== 1 error in 0.12s ==============================================================================================
I think you mentioned that it is necessary to update the test to use the new qa-framework
. If there is no other issue for it, I think this PR would be a good place to do it.
Also, remember to include 3 execution outputs as I mentioned here before moving the issue to pending final review
.
@Selutario the
Let me know if I'm missing something here because I can't reproduce the error. Test run evidenceRun 1
(wqa310) ➜ wazuh-qa git:(4282-update-framework-known-flaws-4-8-0) date; pytest tests/scans/code_analysis/test_python_flaws.py --disable-warnings --exclude_directories tests,test --reference master; git status
Tue Aug 29 10:31:04 AM -03 2023
================================================================================================ test session starts ================================================================================================
platform linux -- Python 3.10.12, pytest-7.1.2, pluggy-1.2.0
rootdir: /home/nstefani/git/wazuh-qa/tests, configfile: pytest.ini
plugins: html-3.1.1, metadata-3.0.0, testinfra-5.0.0
collected 1 item
tests/scans/code_analysis/test_python_flaws.py . [100%]
========================================================================================== 1 passed, 3 warnings in 36.58s ===========================================================================================
On branch 4282-update-framework-known-flaws-4-8-0
nothing to commit, working tree clean Run 2
(wqa310) ➜ wazuh-qa git:(4282-update-framework-known-flaws-4-8-0) date; pytest tests/scans/code_analysis/test_python_flaws.py --disable-warnings --exclude_directories tests,test --reference master; git status
Tue Aug 29 10:34:05 AM -03 2023
================================================================================================ test session starts ================================================================================================
platform linux -- Python 3.10.12, pytest-7.1.2, pluggy-1.2.0
rootdir: /home/nstefani/git/wazuh-qa/tests, configfile: pytest.ini
plugins: html-3.1.1, metadata-3.0.0, testinfra-5.0.0
collected 1 item
tests/scans/code_analysis/test_python_flaws.py . [100%]
========================================================================================== 1 passed, 3 warnings in 36.76s ===========================================================================================
On branch 4282-update-framework-known-flaws-4-8-0
nothing to commit, working tree clean Run 3
(wqa310) ➜ wazuh-qa git:(4282-update-framework-known-flaws-4-8-0) date; pytest tests/scans/code_analysis/test_python_flaws.py --disable-warnings --exclude_directories tests,test --reference master; git status
Tue Aug 29 10:38:48 AM -03 2023
================================================================================================ test session starts ================================================================================================
platform linux -- Python 3.10.12, pytest-7.1.2, pluggy-1.2.0
rootdir: /home/nstefani/git/wazuh-qa/tests, configfile: pytest.ini
plugins: html-3.1.1, metadata-3.0.0, testinfra-5.0.0
collected 1 item
tests/scans/code_analysis/test_python_flaws.py . [100%]
========================================================================================== 1 passed, 3 warnings in 51.05s ===========================================================================================
On branch 4282-update-framework-known-flaws-4-8-0
nothing to commit, working tree clean |
cd849fe
to
09c4a99
Compare
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.
You are right, I forgot to reinstall wazuh_testing
using the master branch. LGTM.
Description
This PR updates the framework file of known flaws with the recent scan results.
Updated
Tests