func (s *MigrationImportSuite) AssertMachineEqual(c *gc.C, newMachine, oldMachine *state.Machine) { c.Assert(newMachine.Id(), gc.Equals, oldMachine.Id()) c.Assert(newMachine.Principals(), jc.DeepEquals, oldMachine.Principals()) c.Assert(newMachine.Series(), gc.Equals, oldMachine.Series()) c.Assert(newMachine.ContainerType(), gc.Equals, oldMachine.ContainerType()) newHardware, err := newMachine.HardwareCharacteristics() c.Assert(err, jc.ErrorIsNil) oldHardware, err := oldMachine.HardwareCharacteristics() c.Assert(err, jc.ErrorIsNil) c.Assert(newHardware, jc.DeepEquals, oldHardware) c.Assert(newMachine.Jobs(), jc.DeepEquals, oldMachine.Jobs()) c.Assert(newMachine.Life(), gc.Equals, oldMachine.Life()) newTools, err := newMachine.AgentTools() c.Assert(err, jc.ErrorIsNil) oldTools, err := oldMachine.AgentTools() c.Assert(err, jc.ErrorIsNil) c.Assert(newTools, jc.DeepEquals, oldTools) }