CWIS Developer Documentation

- Home
- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions | Static Protected Attributes | List of all members
Resource_Test Class Reference
Inheritance diagram for Resource_Test:
[legend]
Collaboration diagram for Resource_Test:
[legend]

## Public Member Functions
| testResource ()
| This function exercises the Resource get and set methods for each Metadata types using the fields created in setUpBeforeClass(). More...

## Static Public Member Functions
static | setUpBeforeClass ()
| Prior to running any of the tests, this function is run. More...
static | tearDownAfterClass ()
| After to running the tests, this function is run. More...

## Static Protected Attributes
static | $TestFieldIds
static | $TestFields
static | $AdminUser
static | $TestClassification
static | $TestControlledName
static | $TestOptionCName

## Detailed Description

Definition at line 3 of file Resource--Test.php.

## Member Function Documentation

static Resource_Test::setUpBeforeClass | ( |  | ) |
| static

Prior to running any of the tests, this function is run.

It creates all of the test Metadata fields and adds them to class variables $TestFieldIds and $TestFields so each function may use them.

Definition at line 11 of file Resource--Test.php.

References ControlledName\Create(), Classification\Create(), MetadataSchema\MDFTYPE_CONTROLLEDNAME, MetadataSchema\MDFTYPE_DATE, MetadataSchema\MDFTYPE_FLAG, MetadataSchema\MDFTYPE_NUMBER, MetadataSchema\MDFTYPE_OPTION, MetadataSchema\MDFTYPE_PARAGRAPH, MetadataSchema\MDFTYPE_POINT, MetadataSchema\MDFTYPE_REFERENCE, MetadataSchema\MDFTYPE_TEXT, MetadataSchema\MDFTYPE_TIMESTAMP, MetadataSchema\MDFTYPE_TREE, MetadataSchema\MDFTYPE_URL, MetadataSchema\MDFTYPE_USER, and MetadataSchema\SCHEMAID_DEFAULT.

static Resource_Test::tearDownAfterClass | ( |  | ) |
| static

After to running the tests, this function is run.

It deletes all of the test Metadata fields.

Definition at line 70 of file Resource--Test.php.

Resource_Test::testResource | ( |  | ) |

This function exercises the Resource get and set methods for each Metadata types using the fields created in setUpBeforeClass().

Definition at line 91 of file Resource--Test.php.

References Resource\Comments(), Message\Create(), Resource\Create(), Resource\Get(), User\GetAnonymousUser(), Resource\GetAsArray(), StdLib\GetConstantName(), Resource\GetSchemaForResource(), MetadataSchema\MDFTYPE_CONTROLLEDNAME, MetadataSchema\MDFTYPE_DATE, MetadataSchema\MDFTYPE_FLAG, MetadataSchema\MDFTYPE_NUMBER, MetadataSchema\MDFTYPE_OPTION, MetadataSchema\MDFTYPE_PARAGRAPH, MetadataSchema\MDFTYPE_POINT, MetadataSchema\MDFTYPE_REFERENCE, MetadataSchema\MDFTYPE_TEXT, MetadataSchema\MDFTYPE_TIMESTAMP, MetadataSchema\MDFTYPE_TREE, MetadataSchema\MDFTYPE_URL, MetadataSchema\MDFTYPE_USER, Message\PARENTTYPE_RESOURCE, and MetadataSchema\SCHEMAID_DEFAULT.

## Member Data Documentation

Resource_Test::$AdminUser
| static protected

Definition at line 614 of file Resource--Test.php.

Resource_Test::$TestClassification
| static protected

Definition at line 615 of file Resource--Test.php.

Resource_Test::$TestControlledName
| static protected

Definition at line 616 of file Resource--Test.php.

Resource_Test::$TestFieldIds
| static protected

Definition at line 612 of file Resource--Test.php.

Resource_Test::$TestFields
| static protected

Definition at line 613 of file Resource--Test.php.

Resource_Test::$TestOptionCName
| static protected

Definition at line 617 of file Resource--Test.php.

The documentation for this class was generated from the following file:

- objects/tests/Resource--Test.php