def _test_create_object_with_attribute_not_in_allowed_choices_list_should_fail(self, attribute):
        """ Create an object with a wrong choice attribute """

        setattr(self.sdkobject, attribute.local_name, "A random value")
        (obj, connection) = self.parent.create_child(self.sdkobject)
        self.last_connection = connection

        self.assertConnectionStatus(connection, 409)
def _test_create_object_with_attribute_not_in_allowed_choices_list_should_fail ( self , attribute ) : setattr ( self . sdkobject , attribute . local_name , "A random value" ) ( obj , connection ) = self . parent . create_child ( self . sdkobject ) self . last_connection = connection self . assertConnectionStatus ( connection , 409 )
Create an object with a wrong choice attribute