'Moving an ``Application`` from one node to another results in a new
``Deployment`` instance reflecting the updated configuration.'

def test_move_application(self):

    application = Application(name=u'mycontainer', image=DockerImage.from_string(u'busybox'))
    original_nodes = [Node(hostname=u'192.0.2.1', applications={application.name: application}), Node(hostname=u'192.0.2.2', applications={})]
    updated_nodes = [Node(hostname=u'192.0.2.1', applications={}), Node(hostname=u'192.0.2.2', applications={application.name: application})]
    original = Deployment(nodes=original_nodes)
    expected = Deployment(nodes=updated_nodes)
    updated = original.move_application(application, original_nodes[1])
    self.assertEqual(updated, expected)
