function SchemaMetatagTestHelper::createContentType in Schema.org Metatag 7
Create a content type for the tests.
File
- tests/
schema_metatag.helper.test, line 38
Class
- SchemaMetatagTestHelper
- A base class for the Metatag tests, provides shared methods.
Code
function createContentType($machine_name, $label) {
// Create a content type.
$content_type = $this
->drupalCreateContentType(array(
'type' => $machine_name,
'name' => $label,
));
// Enable meta tags for this new content type.
metatag_entity_type_enable('node', $machine_name, TRUE);
return $content_type;
}