'Check that a recordset remains the same, even after updates.'

@mute_logger('odoo.models')
def test_05_immutable(self):

    domain = [('name', 'ilike', 'j')]
    partners = self.env['res.partner'].search(domain)
    self.assertTrue(partners)
    ids = map(int, partners)
    partners.write({'active': False})
    self.assertEqual(ids, map(int, partners))
    partners2 = self.env['res.partner'].search(domain)
    self.assertFalse(partners2)
