update() 공개 메소드

public update ( $public_id, $options = [] )
예제 #1
0
 function test_update_parameters()
 {
     Curl::mockApi($this);
     $this->api->update(self::$api_test, array("auto_tagging" => 0.5));
     assertUrl($this, '/resources/image/upload/' . self::$api_test);
     assertParam($this, "auto_tagging", 0.5);
     $fields = Curl::$instance->fields();
     $this->assertArrayNotHasKey("face_coordinates", $fields, "update() should not send empty parameters");
     $this->assertArrayNotHasKey("tags", $fields, "update() should not send empty parameters");
     $this->assertArrayNotHasKey("context", $fields, "update() should not send empty parameters");
     $this->assertArrayNotHasKey("face_coordinates", $fields, "update() should not send empty parameters");
     $this->assertArrayNotHasKey("custom_coordinates", $fields, "update() should not send empty parameters");
 }
 /**
  * @expectedException \Cloudinary\Api\BadRequest
  * @expectedExceptionMessage Must use
  */
 function test26_auto_tagging()
 {
     // should support requesting auto_tagging
     $this->api->update("api_test", array("auto_tagging" => 0.5));
 }