Merge branch 'mig/13.0/delivery_partner_fedex' into 13.0-test

# Conflicts:
#	delivery_partner_fedex/__init__.py
#	delivery_partner_fedex/__manifest__.py
#	delivery_partner_fedex/tests/test_fedex_account.py
This commit is contained in:
Leighton Pennicott
2020-11-06 18:00:39 -05:00
3 changed files with 12 additions and 4 deletions

View File

@@ -1,2 +1 @@
from . import models
from . import tests

View File

@@ -1,7 +1,7 @@
{
'name': 'Fedex Partner Shipping Accounts',
'author': 'Hibou Corp. <hello@hibou.io>',
'version': '12.0.1.0.0',
'version': '13.0.1.0.0',
'category': 'Stock',
'sequence': 95,
'summary': 'Fedex Partner Shipping Accounts',

View File

@@ -7,6 +7,7 @@ class TestAccount(TransactionCase):
def setUp(self):
super(TestAccount, self).setUp()
self.PartnerShippingAccount = self.env['partner.shipping.account']
self.partner = self.env.ref('base.res_partner_12')
def test_fedex_account_information(self):
# Create object and confirm that validation error raises if fedex account is blank or not 8 digits
@@ -14,7 +15,7 @@ class TestAccount(TransactionCase):
wrong_account_number = self.PartnerShippingAccount.create({
'name': '12345678',
'description': 'Error Account',
'partner_id': 5,
'partner_id': self.partner.id,
'delivery_type': 'fedex',
'note': 'This is a note'
})
@@ -23,7 +24,15 @@ class TestAccount(TransactionCase):
no_account_number = self.PartnerShippingAccount.create({
'name': '',
'description': 'Error Account',
'partner_id': 5,
'partner_id': self.partner.id,
'delivery_type': 'fedex',
'note': 'This is a note'
})
_ = self.PartnerShippingAccount.create({
'name': '123456789',
'description': 'Error Account',
'partner_id': self.partner.id,
'delivery_type': 'fedex',
'note': 'This is a note'
})