mirror of
https://github.com/bringout/oca-ocb-sale.git
synced 2026-04-27 03:32:04 +02:00
19.0 vanilla
This commit is contained in:
parent
79f83631d5
commit
73afc09215
6267 changed files with 1534193 additions and 1130106 deletions
|
|
@ -1,9 +1,13 @@
|
|||
# -*- encoding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
from odoo.addons.website_sale_autocomplete.controllers.main import AutoCompleteController
|
||||
from odoo.tests import patch, HttpCase, tagged
|
||||
|
||||
CONTROLLER_PATH = 'odoo.addons.website_sale_autocomplete.controllers.main.AutoCompleteController'
|
||||
from odoo.tests import HttpCase, patch, tagged
|
||||
|
||||
from odoo.addons.google_address_autocomplete.controllers.google_address_autocomplete import (
|
||||
AutoCompleteController,
|
||||
)
|
||||
|
||||
|
||||
CONTROLLER_PATH = 'odoo.addons.google_address_autocomplete.controllers.google_address_autocomplete.AutoCompleteController'
|
||||
MOCK_GOOGLE_ID = 'aHR0cHM6Ly93d3cueW91dHViZS5jb20vd2F0Y2g/dj1kUXc0dzlXZ1hjUQ=='
|
||||
MOCK_API_KEY = 'Tm9ib2R5IGV4cGVjdHMgdGhlIFNwYW5pc2ggaW5xdWlzaXRpb24gIQ=='
|
||||
|
||||
|
|
@ -22,8 +26,8 @@ class TestUI(HttpCase):
|
|||
def test_autocomplete(self):
|
||||
with patch.object(AutoCompleteController, '_perform_complete_place_search',
|
||||
lambda controller, *args, **kwargs: {
|
||||
'country': self.env['res.country'].search([('code', '=', 'USA')]).id,
|
||||
'state': self.env['res.country.state'].search([('country_id.code', '=', 'USA')])[0].id,
|
||||
'country': [self.env['res.country'].search([('code', '=', 'USA')]).id, 'United States'],
|
||||
'state': [self.env['res.country.state'].search([('country_id.code', '=', 'USA')])[0].id, 'Alabama'],
|
||||
'zip': '12345',
|
||||
'city': 'A Fictional City',
|
||||
'street': 'A fictional Street',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue