You are here

public function VideoFieldTestCase::testVideoFieldValidate in Video 7.2

Tests validation logic in video_field_validate().

File

tests/VideoField.test, line 352
Tests for the the Video field type

Class

VideoFieldTestCase
Tests for the the Video field type

Code

public function testVideoFieldValidate() {

  // Build test data
  $file = $this
    ->createFile('test.txt', 'text/plain');
  $node = new stdClass();
  $node->uid = $this->user->uid;
  $node->type = 'page';
  $node->title = 'Test node';
  $node->videofield['und'][0] = array(
    'fid' => $file->fid,
    'dimensions' => '100x60',
  );
  node_save($node);
}