============================= test session starts ============================== platform sunos5 -- Python $(PYTHON_VERSION).X -- $(PYTHON) cachedir: .pytest_cache rootdir: $(@D) configfile: pyproject.toml testpaths: tests X workers [139 items] scheduling tests via LoadScheduling tests/e2e/test_cli.py::test_check_one_file_changes PASSED tests/e2e/test_cli.py::test_check_one_file_no_changes PASSED tests/e2e/test_cli.py::test_config_parsing PASSED tests/e2e/test_cli.py::test_corrects_code_from_stdin PASSED tests/e2e/test_cli.py::test_corrects_one_file PASSED tests/e2e/test_cli.py::test_corrects_three_files PASSED tests/e2e/test_cli.py::test_do_not_read_folders_as_files PASSED tests/e2e/test_cli.py::test_find_files PASSED tests/e2e/test_cli.py::test_ignores_correct_files PASSED tests/e2e/test_cli.py::test_include_exclude_files PASSED tests/e2e/test_cli.py::test_no_yaml_files PASSED tests/e2e/test_cli.py::test_read_prefixed_environment_variables PASSED tests/e2e/test_cli.py::test_sequence_style_env_enum_parsing PASSED tests/e2e/test_cli.py::test_std_and_file_error PASSED tests/e2e/test_cli.py::test_verbose_option[0-False] PASSED tests/e2e/test_cli.py::test_verbose_option[0-True] PASSED tests/e2e/test_cli.py::test_verbose_option[1-False] PASSED tests/e2e/test_cli.py::test_verbose_option[1-True] PASSED tests/e2e/test_cli.py::test_verbose_option[2-False] PASSED tests/e2e/test_cli.py::test_verbose_option[2-True] PASSED tests/e2e/test_cli.py::test_version PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_comment_spacing_config PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_dont_allow_duplicate_keys_config PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_dont_generate_explicit_start PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_empty_list_inline_comment_indentation PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_enforcing_flow_style_together_with_adjustable_newlines PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_if_line_length_contracts PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_if_line_length_expands PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_indentation_config PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_none_representation_config[NULL] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_none_representation_config[Null] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_none_representation_config[] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_none_representation_config[null] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_none_representation_config[~] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_preserve_quotes_config PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_all_keys_and_values_config["] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_all_keys_and_values_config['] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_all_keys_and_values_config_and_preserve_quotes["] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_all_keys_and_values_config_and_preserve_quotes['] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_values_config["] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_values_config['] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_values_config_and_preserve_quotes["] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_quote_values_config_and_preserve_quotes['] PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_section_whitelines PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_section_whitelines_begin_no_explicit_start PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_sequence_block_style_config PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_sequence_block_style_enforcement_for_lists_longer_than_line_length PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_sequence_block_style_enforcement_for_lists_with_comments PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_sequence_block_style_enforcement_for_lists_with_non_scalar_values PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_sequence_flow_style_config PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_sequence_flow_style_with_trailing_newlines PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_sequence_keep_style_config PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_whitelines_adjusted_to_value PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_whitelines_collapsed PASSED tests/unit/test_adapter_yaml.py::TestYamlAdapter::test_whitelines_higher_than_secion_whitelines PASSED tests/unit/test_services.py::TestFixCode::test_anchors_and_aliases_with_duplicate_merge_keys PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_add_extra_space_inline_comment PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_add_space_inline_comment PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_adds_header PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_adds_space_in_comment PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[FALSE] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[False] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[NO] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[No] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[OFF] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[Off] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[false] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[no] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_false_booleans[off] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[ON] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[On] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[TRUE] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[True] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[YES] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[Yes] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[on] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[true] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_converts_non_valid_true_booleans[yes] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_corrects_indentation_on_lists PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_doesnt_change_double_exclamation_marks PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_doesnt_double_the_header PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_doesnt_remove_variable PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n# Comment: desired: 2 lines before this comment\nkey: value\n-config8----\nlist: [item, item]\n\n\n# Comment: desired: 2 lines before this comment\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n# Comment: desired: 0 line before this comment\nkey: value\n-config6----\nlist: [item, item]\n# Comment: desired: 0 line before this comment\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n# Comment: desired: 1 line (default) before this comment\nkey: value\n-None----\nlist: [item, item]\n\n# Comment: desired: 1 line (default) before this comment\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n# Comment: desired: 1 line before this comment\nkey: value\n-config5----\nlist: [item, item]\n\n# Comment: desired: 1 line before this comment\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n# Comment: desired: 2 lines before this comment\nkey: value\n-config7----\nlist: [item, item]\n\n\n# Comment: desired: 2 lines before this comment\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n\nkey: value # Comment: desired: No lines between `list` and `key`\n-config2----\nlist: [item, item]\nkey: value # Comment: desired: No lines between `list` and `key`\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n\nkey: value # Comment: desired: No lines between `list` and `key`\n-config3----\nlist: [item, item]\nkey: value # Comment: desired: No lines between `list` and `key`\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n\nkey: value # Comment: desired: No lines between `list` and `key`\n-config4----\nlist: [item, item]\nkey: value # Comment: desired: No lines between `list` and `key`\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist: [item, item]\n\n\n\nkey: value\n-config1----\nlist: [item, item]\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist:\n - item\n # Comment: desired: 0 new line before this comment\n - item\n\nkey: value\n-config10----\nlist:\n - item\n # Comment: desired: 0 new line before this comment\n - item\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist:\n - item\n # Comment: desired: 0 new line before this comment\n - item\n\nkey: value\n-config11----\nlist:\n - item\n # Comment: desired: 0 new line before this comment\n - item\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist:\n - item\n # Comment: desired: 0 new line before this comment\n - item\n\nkey: value\n-config9----\nlist:\n - item\n # Comment: desired: 0 new line before this comment\n - item\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist:\n - item\n\n # Comment: desired: 1 new line before this comment\n - item\n\nkey: value\n-config12----\nlist:\n - item\n\n # Comment: desired: 1 new line before this comment\n - item\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_fix_whitelines[---\nlist:\n - item\n\n # Comment: desired: 2 new lines before this comment\n - item\n\nkey: value\n-config13----\nlist:\n - item\n\n\n # Comment: desired: 2 new lines before this comment\n - item\nkey: value\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_functions_emit_debug_logs PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_ignore_ansible_vaults PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_ignore_jinja2 PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_ignore_shebang PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_not_add_extra_space_in_comment PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_parses_files_with_multiple_documents PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_preserves_comments PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_preserves_indented_comments[---\n- name: Setup SONiC Build Servers\n hosts: sonic_build_server\n vars:\n # Keep comments!\n build_user: build\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_preserves_indented_comments[---\n- program:\n # Keep comments!\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_preserves_indented_comments[---\ntasks:\n - name: Make sure repository is cloned # noqa latest[git]\n] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_removes_extra_apostrophes PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[FALSE] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[False] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[NO] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[No] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[OFF] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[ON] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[Off] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[On] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[TRUE] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[True] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[YES] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[Yes] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[false] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[no] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[off] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[on] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[true] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_apostrophes_for_truthy_substitutions[yes] PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_comment_symbol_in_strings_with_double_quotes PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_comment_symbol_in_strings_with_simple_quotes PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_jinja_variables_with_equals PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_jinja_variables_with_operations PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_many_jinja_variables PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_parent_lists PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_parent_lists_with_comments PASSED tests/unit/test_services.py::TestFixCode::test_fix_code_respects_url_anchors PASSED tests/unit/test_services.py::TestFixCode::test_fixed_code_has_exactly_one_newline_at_end_of_file[\n\n] PASSED tests/unit/test_services.py::TestFixCode::test_fixed_code_has_exactly_one_newline_at_end_of_file[\n] PASSED tests/unit/test_services.py::TestFixCode::test_fixed_code_has_exactly_one_newline_at_end_of_file[] PASSED tests/unit/test_services.py::TestFixFiles::test_fix_files_can_process_string_arguments PASSED tests/unit/test_services.py::TestFixFiles::test_fix_files_issues_warning PASSED tests/unit/test_version.py::test_version PASSED ======== 139 passed ========