'In previous versions we had rounding and efficiency fields.  We check if we can still do the same, but with only the rounding on the UoM'

def test_rounding(self):

    self.product_6.uom_id.rounding = 1.0
    bom_eff = self.env['mrp.bom'].create({'product_id': self.product_6.id, 'product_tmpl_id': self.product_6.product_tmpl_id.id, 'product_qty': 1, 'product_uom_id': self.product_6.uom_id.id, 'type': 'normal', 'bom_line_ids': [(0, 0, {'product_id': self.product_2.id, 'product_qty': 2.03}), (0, 0, {'product_id': self.product_8.id, 'product_qty': 4.16})]})
    production = self.env['mrp.production'].create({'name': 'MO    efficiency    test', 'product_id': self.product_6.id, 'product_qty': 20, 'bom_id': bom_eff.id, 'product_uom_id': self.product_6.uom_id.id})
    self.assertEqual(production.move_raw_ids[0].product_qty, 41, 'The    quantity    should    be    rounded    up')
    self.assertEqual(production.move_raw_ids[1].product_qty, 84, 'The    quantity    should    be    rounded    up')
    produce_wizard = self.env['mrp.product.produce'].with_context({'active_id': production.id, 'active_ids': [production.id]}).create({'product_qty': 8})
    produce_wizard.do_produce()
    self.assertEqual(production.move_raw_ids[0].quantity_done, 16, 'Should    use    half-up    rounding    when    producing')
    self.assertEqual(production.move_raw_ids[1].quantity_done, 34, 'Should    use    half-up    rounding    when    producing')
