You are here

protected function DateTestCase::getMapping in Microdata 7

Implements MicrodataFieldTestCase::getMapping().

Overrides MicrodataFieldTestCase::getMapping

File

modules/date/date.test, line 107
Tests for Date module.

Class

DateTestCase
Test Date module microdata placement.

Code

protected function getMapping() {
  foreach ($this->dateTypes as $date_type) {
    foreach ($this->fieldFormatterTypes as $type) {
      $mapping[$this->entityType][$this->bundleType]["{$date_type}_{$type}"] = array(
        'value' => array(
          '#itemprop' => array(
            "{$date_type}_{$type}_start",
          ),
        ),
        'value2' => array(
          '#itemprop' => array(
            "{$date_type}_{$type}_end",
          ),
        ),
      );
    }
  }
  $mapping[$this->entityType][$this->bundleType]['single_date'] = array(
    '#itemprop' => array(
      "single_date_start",
    ),
  );
  return $mapping;
}