Skip to content

Commit

Permalink
[IMP] account_invoice_line_stock_move_info: Change test.
Browse files Browse the repository at this point in the history
  • Loading branch information
alfredoavanzosc committed Dec 14, 2015
1 parent 02aba3d commit e043b71
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,10 @@ def setUp(self):

def test_confirm_sale_and_generate_invoice(self):
self.sale_order.action_button_confirm()
cond = [('sale_id', '=', self.sale_order.id)]
picking = self.picking_model.search(cond, limit=1)
pickings = self.picking_model.search([])
# "Filtered" is used because the "sale_id" field of pickings is not
# stored to disk
picking = pickings.filtered(lambda x: x.sale_id == self.sale_order)
self.assertEqual(len(picking), 1, "Picking not found")
picking.force_assign()
self.assertEqual(picking.state, 'assigned', "Picking not assigned")
Expand Down

0 comments on commit e043b71

Please sign in to comment.