Closed verdx closed 11 months ago
One of the three tests fails with a Timeout error.
One of the tests fails with a Timeout Error.
For test_cluster
, different subtests need different inventories, so they will be tested separately:
All tests fail with a timeout error
The provisioning fails if wazuh-branch
is not defined because of the following error in the agent role yaml:
- name: "Get agent package"
ansible.builtin.get_url:
url: "https://{{package_repository}}.wazuh.com/{{repository}}/apt/pool/main/w/wazuh-agent/wazuh-agent_{{package_version}}-{{package_revision}}_amd64.deb"
dest: /tmp/wazuh-manager.deb
when: wazuh_branch is not defined
- name: "Install agent package"
ansible.builtin.apt:
deb: /tmp/wazuh-agent.deb
when: wazuh_branch is not defined
The package is downloaded as wazuh-manager.deb
but is installed as wazuh-agent.deb
When called with parameter wazuh_branch
, the provisioning is done correctly and the tests can be run, but all tests in test_fim/test_synchronization
and some in test_fim/test_files
fail with Timeout errors.
All tests passed.
All tests passed.
Need to update https://github.com/wazuh/wazuh-qa/issues/4247#issue-1774284592 for system tests.
The tests path in the spreadsheets is wrong, it should be system
instead of integration
.
We should document how tests are launched locally (we can use the README), what environments there are, and that we should be aware that some tests may leave the environment dirty and cause other tests to fail.
Jenkins parameters are shown but not explained.
Main comment (https://github.com/wazuh/wazuh-qa/issues/4247#issue-1774284592) updated with requested changes.
Tests shown in All possible tests
are integration tests
Rest to be completed as part of redesign work
Description
This issue aims to analyze and document all about the System test. Jenkins parameters, pytest location, steps in the test and current state of it.
State
Tests done
- https://ci.wazuh.info/job/Test_system/88 - https://ci.wazuh.info/job/Test_system/89 - https://ci.wazuh.info/job/Test_system/90 - https://ci.wazuh.info/job/Test_system/91 - https://ci.wazuh.info/job/Test_system/92 - https://ci.wazuh.info/job/Test_system/93 - https://ci.wazuh.info/job/Test_system/94The pipeline fails with the error:
The failing function is
readJSON
, insidegetTestProvisioning
, insidesetParameters
, in stageInit Environment
, in pipelinetest_system.groovy
.As the pipeline does not run, manual tests have been done on an Ubuntu 22 machine and the results are in the following comments.
Basically, the results are that all tests pass but sometimes they fail with a timeout error, all errors would probably be fixed if the timeouts are increased.
Possible subtests
The whole test directory structure is explained here (in this comment are shown the
integration
tests, but the structure is the same). Basically, the possible tests to run are the directories inside the directorytests/system
in https://github.com/wazuh/wazuh-qa. The test you want to run is defined in parameterTEST_PATH
. They are the following:All possible tests
``` ├── test_active_response │ ├── test_analysisd │ └── test_execd ├── test_agentd ├── test_analysisd │ ├── test_all_syscheckd_configurations │ │ └── yaml_generators │ ├── test_error_messages │ ├── test_event_messages │ ├── test_integrity_messages │ ├── test_limit_eps │ ├── test_mitre │ ├── test_predecoder_stage │ ├── test_queue_socket_properties │ ├── test_scan_messages │ ├── test_signature_id │ └── test_syscollector ├── test_api │ ├── test_config │ │ ├── test_bruteforce_blocking_system │ │ ├── test_cache │ │ ├── test_cors │ │ ├── test_DOS_blocking_system │ │ ├── test_drop_privileges │ │ ├── test_experimental_features │ │ ├── test_host_port │ │ ├── test_https │ │ ├── test_jwt_token_exp_timeout │ │ ├── test_logs │ │ ├── test_max_upload_size │ │ ├── test_rbac │ │ └── test_request_timeout │ ├── test_middlewares │ ├── test_rbac │ └── test_statistics ├── test_authd │ ├── files │ └── force_options ├── test_enrollment ├── test_fim │ ├── test_files │ │ ├── test_ambiguous_confs │ │ ├── test_audit │ │ ├── test_basic_usage │ │ ├── test_env_variables │ │ ├── test_file_limit │ │ ├── test_follow_symbolic_link │ │ ├── test_ignore │ │ ├── test_inotify │ │ ├── test_max_eps │ │ ├── test_moving_files │ │ ├── test_prefilter_cmd │ │ ├── test_process_priority │ │ ├── test_recursion_level │ │ ├── test_report_changes │ │ ├── test_restrict │ │ ├── test_scan │ │ ├── test_skip │ │ ├── test_tags │ │ ├── test_timezone_changes │ │ └── test_windows_audit_interval │ ├── test_registry │ │ ├── test_registry_ambiguous_confs │ │ ├── test_registry_basic_usage │ │ ├── test_registry_checks │ │ ├── test_registry_file_limit │ │ ├── test_registry_ignore │ │ ├── test_registry_multiple_registries │ │ ├── test_registry_nodiff │ │ ├── test_registry_report_changes │ │ │ └── test_disk_quota │ │ ├── test_registry_restrict │ │ └── test_registry_tags │ └── test_synchronization ├── test_gcloud │ ├── test_configuration │ └── test_functionality ├── test_github │ └── test_configuration ├── test_integratord ├── test_logcollector │ ├── test_age │ ├── test_command_monitoring │ ├── test_configuration │ ├── test_keep_running │ ├── test_localfile │ ├── test_location │ ├── test_location_custom_sockets │ ├── test_log_format │ ├── test_macos │ ├── test_only_future_events │ ├── test_options │ ├── test_reconnect_time │ └── test_statistics ├── test_logtest │ ├── test_configuration │ ├── test_invalid_rule_decoders_syntax │ ├── test_invalid_socket_input │ ├── test_invalid_token │ ├── test_log_process_options │ ├── test_remove_old_sessions │ ├── test_remove_session │ ├── test_rules_decoders_load │ └── test_ruleset_refresh ├── test_office365 │ └── test_configuration ├── test_remoted │ ├── test_active_response │ ├── test_agent_communication │ ├── test_configuration │ ├── test_manager_messages │ ├── test_multi_groups │ └── test_socket_communication ├── test_rids ├── test_rootcheck ├── test_syscollector ├── test_vulnerability_detector │ ├── test_cpe_helper │ ├── test_feeds │ ├── test_general_settings │ ├── test_providers │ ├── test_scan_results │ ├── test_scan_types │ └── test_vulnerability_inventory ├── test_wazuh_db └── test_wpk ```Parameters
wazuh-jenkins
repository's commit or branch/tag.wazuh-qa
repository's commit or branch/tag.pytest
execution. Default-v --tb=short
.Local execution
This test suite can be executed locally as well, to do so, you have to follow these steps:
wazuh-qa
repositorywazuh-testing
library