function ImageToolkitUnitTest::testLoad

Test the image_load() function.

File

modules/simpletest/tests/image.test, line 101

Class

ImageToolkitUnitTest
Test that the functions in image.inc correctly pass data to the toolkit.

Code

function testLoad() {
  $image = image_load($this->file, $this->toolkit);
  $this->assertTrue(is_object($image), 'Returned an object.');
  $this->assertEqual($this->toolkit, $image->toolkit, 'Image had toolkit set.');
  $this->assertToolkitOperationsCalled(array(
    'load',
    'get_info',
  ));
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.