You are here

function entity_test_schema in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/system/tests/modules/entity_test/entity_test.install \entity_test_schema()

Implements hook_schema().

File

core/modules/system/tests/modules/entity_test/entity_test.install, line 41
Install, update and uninstall functions for the entity_test module.

Code

function entity_test_schema() {

  // Schema for simple entity.
  $schema['entity_test_example'] = [
    'description' => 'Stores entity_test items.',
    'fields' => [
      'id' => [
        'type' => 'serial',
        'not null' => TRUE,
        'description' => 'Primary Key: Unique entity-test item ID.',
      ],
    ],
    'primary key' => [
      'id',
    ],
  ];
  return $schema;
}