Reviewers: ,
Please review this at http://codereview.tryton.org/167003/ Affected files: M tests/test_party.py Index: tests/test_party.py =================================================================== --- a/tests/test_party.py +++ b/tests/test_party.py @@ -52,7 +52,7 @@ ''' Test category recursion. ''' - with Transaction().start(DB_NAME, USER, CONTEXT) as transaction: + with Transaction().start(DB_NAME, USER, CONTEXT): category1_id = self.category.search([ ('name', '=', 'Category 1'), ], limit=1)[0] @@ -83,7 +83,7 @@ ''' Test party code constraint. ''' - with Transaction().start(DB_NAME, USER, CONTEXT) as transaction: + with Transaction().start(DB_NAME, USER, CONTEXT): party1_id = self.party.search([], limit=1)[0] code = self.party.read(party1_id, ['code'])['code'] @@ -101,10 +101,10 @@ ''' Create address. ''' - with Transaction().start(DB_NAME, USER, CONTEXT) as transaction: + with Transaction().start(DB_NAME, USER, CONTEXT): party1_id = self.party.search([], limit=1)[0] - address1_id = self.address.create({ + self.address.create({ 'party': party1_id, 'street': 'St sample, 15', 'city': 'City', -- [email protected] mailing list
