Skip to content
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

[13.0][FIX] l10n_nl_location_nuts: mocked tests #309

Merged
merged 1 commit into from
Mar 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/l10n_nl_xaf_auditfile_export/views/templates.xml
/l10n_nl_location_nuts/tests/vcr_cassettes/nuts_import.yaml
17 changes: 16 additions & 1 deletion l10n_nl_location_nuts/tests/test_l10n_nl_location_nuts.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,32 @@
# Copyright 2018-2019 Onestein (<https://www.onestein.eu>)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).

import logging
from os.path import dirname, join

from vcr import VCR

from odoo.tests.common import TransactionCase

from ..hooks import post_init_hook

logging.getLogger("vcr").setLevel(logging.WARNING)

recorder = VCR(
record_mode="once",
cassette_library_dir=join(dirname(__file__), "vcr_cassettes"),
path_transformer=VCR.ensure_suffix(".yaml"),
filter_headers=["Authorization"],
)


class TestNlLocationNuts(TransactionCase):
def setUp(self):
super().setUp()

importer = self.env["nuts.import"]
importer.run_import()
with recorder.use_cassette("nuts_import"):
importer.run_import()

def test_dutch_nuts(self):
"""
Expand Down
Loading