Browse Source

[MIG+FIX] base_location_geonames_import: Adjust tests + setup

14.0
Pedro M. Baeza 4 years ago
parent
commit
bfa814b23e
  1. 6
      base_location_geonames_import/tests/test_base_location_geonames_import.py
  2. 1
      setup/base_location_geonames_import/odoo/addons/base_location_geonames_import
  3. 6
      setup/base_location_geonames_import/setup.py

6
base_location_geonames_import/tests/test_base_location_geonames_import.py

@ -1,4 +1,4 @@
# Copyright 2016-2019 Pedro M. Baeza <pedro.baeza@tecnativa.com>
# Copyright 2016-2020 Tecnativa - Pedro M. Baeza
# Copyright 2020 Manuel Regidor <manuel.regidor@sygel.es> # Copyright 2020 Manuel Regidor <manuel.regidor@sygel.es>
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
@ -30,7 +30,7 @@ class TestBaseLocationGeonamesImport(common.SavepointCase):
) )
cls.country_4 = cls.env.ref("base.ad") cls.country_4 = cls.env.ref("base.ad")
cls.wizard_3 = cls.env["city.zip.geonames.import"].create( cls.wizard_3 = cls.env["city.zip.geonames.import"].create(
{"country_id": cls.country_4.id}
{"country_ids": [(4, cls.country_4.id)]}
) )
def test_import_country(self): def test_import_country(self):
@ -117,7 +117,7 @@ class TestBaseLocationGeonamesImport(common.SavepointCase):
def test_import_duplicated_city_name(self): def test_import_duplicated_city_name(self):
country = self.env.ref("base.us") country = self.env.ref("base.us")
self.wizard.country_id = country.id
self.wizard.country_ids = [(6, 0, country.ids)]
parsed_csv = [ parsed_csv = [
[ [
"US", "US",

1
setup/base_location_geonames_import/odoo/addons/base_location_geonames_import

@ -0,0 +1 @@
../../../../base_location_geonames_import

6
setup/base_location_geonames_import/setup.py

@ -0,0 +1,6 @@
import setuptools
setuptools.setup(
setup_requires=['setuptools-odoo'],
odoo_addon=True,
)
Loading…
Cancel
Save