From 3224f10f453a09a8cd934e761e1b2a4927ac5864 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alvaro=20Andr=C3=A9s=20Rodr=C3=ADguez=20Scelza?= Date: Fri, 7 Jun 2019 14:27:04 -0300 Subject: [PATCH] line tests ready --- .../automatic_testing/general_hooks/check_line_test.py | 4 ++++ .../check_line_samples/xml_lines_error_1.xml | 9 +++++++++ 2 files changed, 13 insertions(+) create mode 100644 pre_commit_hooks/loaderon_hooks/tests/automatic_testing/testing_files/check_line_samples/xml_lines_error_1.xml diff --git a/pre_commit_hooks/loaderon_hooks/tests/automatic_testing/general_hooks/check_line_test.py b/pre_commit_hooks/loaderon_hooks/tests/automatic_testing/general_hooks/check_line_test.py index 07ab4b6..1bd6b0c 100644 --- a/pre_commit_hooks/loaderon_hooks/tests/automatic_testing/general_hooks/check_line_test.py +++ b/pre_commit_hooks/loaderon_hooks/tests/automatic_testing/general_hooks/check_line_test.py @@ -43,3 +43,7 @@ def clean_sys_argv(): def test_odoo_xml_field_and_record_declaration_ok(): perform_test_on_file_expecting_result('check_line_samples/xml_lines_ok.xml', main) + + +def test_odoo_xml_record_declaration_error(): + perform_test_on_file_expecting_result('check_line_samples/xml_lines_error_1.xml', main, expected_result=2) diff --git a/pre_commit_hooks/loaderon_hooks/tests/automatic_testing/testing_files/check_line_samples/xml_lines_error_1.xml b/pre_commit_hooks/loaderon_hooks/tests/automatic_testing/testing_files/check_line_samples/xml_lines_error_1.xml new file mode 100644 index 0000000..f3bec45 --- /dev/null +++ b/pre_commit_hooks/loaderon_hooks/tests/automatic_testing/testing_files/check_line_samples/xml_lines_error_1.xml @@ -0,0 +1,9 @@ + + + + + some.model.form.inherit + some.model + + +