diff options
Diffstat (limited to 'modules/field/tests')
-rw-r--r-- | modules/field/tests/field_test.field.inc | 36 | ||||
-rw-r--r-- | modules/field/tests/field_test.install | 36 |
2 files changed, 36 insertions, 36 deletions
diff --git a/modules/field/tests/field_test.field.inc b/modules/field/tests/field_test.field.inc index 6bb8dd87b..603eadd6a 100644 --- a/modules/field/tests/field_test.field.inc +++ b/modules/field/tests/field_test.field.inc @@ -47,42 +47,6 @@ function field_test_field_info() { } /** - * Implements hook_field_schema(). - */ -function field_test_field_schema($field) { - if ($field['type'] == 'test_field') { - return array( - 'columns' => array( - 'value' => array( - 'type' => 'int', - 'size' => 'medium', - 'not null' => FALSE, - ), - ), - 'indexes' => array( - 'value' => array('value'), - ), - ); - } - else { - return array( - 'columns' => array( - 'shape' => array( - 'type' => 'varchar', - 'length' => 32, - 'not null' => FALSE, - ), - 'color' => array( - 'type' => 'varchar', - 'length' => 32, - 'not null' => FALSE, - ), - ), - ); - } -} - -/** * Implements hook_field_update_forbid(). */ function field_test_field_update_forbid($field, $prior_field, $has_data) { diff --git a/modules/field/tests/field_test.install b/modules/field/tests/field_test.install index d16d79ee8..d4937b620 100644 --- a/modules/field/tests/field_test.install +++ b/modules/field/tests/field_test.install @@ -106,3 +106,39 @@ function field_test_schema() { return $schema; } + +/** + * Implements hook_field_schema(). + */ +function field_test_field_schema($field) { + if ($field['type'] == 'test_field') { + return array( + 'columns' => array( + 'value' => array( + 'type' => 'int', + 'size' => 'medium', + 'not null' => FALSE, + ), + ), + 'indexes' => array( + 'value' => array('value'), + ), + ); + } + else { + return array( + 'columns' => array( + 'shape' => array( + 'type' => 'varchar', + 'length' => 32, + 'not null' => FALSE, + ), + 'color' => array( + 'type' => 'varchar', + 'length' => 32, + 'not null' => FALSE, + ), + ), + ); + } +} |