def test_mgr_update_policy_desired_to_desired(self):
        sg = self.scaling_group
        mgr = sg.manager
        pol = utils.random_unicode()
        name = utils.random_unicode()
        ptype = utils.random_unicode()
        cooldown = utils.random_unicode()
        change = utils.random_unicode()
        args = utils.random_unicode()
        new_desired_capacity = 10
        old_info = {"desiredCapacity": 0}
        mgr.get_policy = Mock(
                return_value=fakes.FakeAutoScalePolicy(mgr, old_info, sg))
        mgr.api.method_put = Mock(return_value=(None, None))
        uri = (mgr.uri_base, sg.id, pol) % "/%s/%s/policies/%s"
        put_body = {"name": name, "cooldown": cooldown, "type": ptype,
                "desiredCapacity": new_desired_capacity}
        ret = mgr.update_policy(sg, pol, name=name, policy_type=ptype,
                cooldown=cooldown, desired_capacity=new_desired_capacity)
        mgr.api.method_put.assert_called_with(uri, body=put_body)
dataset/ETHPy150Open rackspace/pyrax/tests/unit/test_autoscale.py/AutoscaleTest.test_mgr_update_policy_desired_to_desired/swapped operands of `%`