You are here

DatePopupValidationTestCase.test in Date 7.2

Same filename and directory in other branches
  1. 7.3 date_popup/tests/DatePopupValidationTestCase.test

Data validation tests for the Date Popup module.

File

date_popup/tests/DatePopupValidationTestCase.test
View source
<?php

/**
 * @file
 * Data validation tests for the Date Popup module.
 */

/**
 * Data validation tests for the Date Popup module.
 */
class DatePopupValidationTestCase extends DateValidationTestCase {

  /**
   * {@inheritdoc}
   */
  public function setUp(array $modules = array()) {
    $modules[] = 'date_popup';
    parent::setUp($modules);
  }

  /**
   * Validate the Date Popup fields.
   */
  public function testValidation() {

    // Attempts to create text date field stored as a date with default settings
    // (from input which is not valid).
    foreach (array(
      'date',
      'datestamp',
      'datetime',
    ) as $field_type) {
      $this
        ->checkDateField($field_type, 'date_popup', TRUE);
      return;
    }
  }

}

Classes

Namesort descending Description
DatePopupValidationTestCase Data validation tests for the Date Popup module.