Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions FlexUnit4/src/locale/en_US/metadata.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
flexunit.test = Annotates a method as a FlexUnit 4 test.
flexunit.runwith = Used to specify a custom runner for a FlexUnit 4 test case. Custom runners must implement the IRunner interface.
flexunit.suite = Annotates a class as a FlexUnit 4 suite. This class also needs to be decorated with the [RunWith(org.flexunit.runners.Suite")] metadata.
flexunit.before = Annotates that a method should be run before every test in this test case.
flexunit.after = Annotates that a method should be run after every test in this test case.
flexunit.beforeclass = Annotates that a method should be run before any tests are executed in this test case.
flexunit.afterclass = Annotates that a method should be run after any tests are executed in this test case.
flexunit.ignore = A test or class decorated with this metadata will not be run and marked as an ignored test during test execution.
flexunit.theory = Specifies a type of test which uses parameters to test a repeatable, mathematical theory.
flexunit.parameters = Used as a part of parameterized testing to specify what array contains parameters for this method.
flexunit.datapoints = Used to specify an array of parameters to be used as part of a theory or parameterized test. A variable decorated with [DataPoints] metadata must also be decorated with [ArrayElementType] specifying the type of the values within the array.
flexunit.datapoint = Specifies a single data point to use with a theory.
flexunit.expects = Used to decorate a test which expects an error to be thrown. The value of this attribute must match the full class package definition of the expected error.
flexunit.order = Notifies the runner of operations that must be handled in a specific order. Operations of the same type are handled in ascending order.
flexunit.description = Generally used to explain the use of a test.
flexunit.timeout = Used with the async annotation to specify a time in milliseconds before a test waiting on an async operation should be marked as a failure.
flexunit.async = Signifies that a test needs to wait for an asynchronous operation. Forces the test to wait until the operation completes. Failing to specify a timeout will cause the runner to hang indefinitely in the case of a failure.
flexunit.ui = Notifies the runner that this operation requires UI interaction. Most ui methods are also asynchronous and should be decorated with the async tag as well.
flexunit.loader = Used to specify a loader for external data. Loaders must implement the IExternalDepedencyLoader interface.
flexunit.dataProvider = Used to specify an array containing the data for a parameterized test.
273 changes: 273 additions & 0 deletions FlexUnit4/src/metadata.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,273 @@
<?xml version="1.0" encoding="utf-8" ?>
<annotations version="1.0">
<metadata name="Test" description="%flexunit.test">
<context name="method" />
<attribute name="async"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.async"
/>
<attribute name="ui"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.ui"
/>
<attribute name="order"
type="Number"
required="false"
description="%flexunit.order"
/>
<attribute name="timeout"
type="Number"
required="false"
description="%flexunit.timeout"
/>
<attribute name="expects"
type="Class"
required="false"
hint="classes"
hintType="Error"
description="%flexunit.expects"
/>
<attribute name="dataProvider"
type="Array"
required="false"
description="%flexunit.dataProvider"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="Before" description="%flexunit.before">
<context name="method" />
<attribute name="async"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.async"
/>
<attribute name="ui"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.ui"
/>
<attribute name="order"
type="Number"
required="false"
description="%flexunit.order"
/>
<attribute name="timeout"
type="Number"
required="false"
description="%flexunit.timeout"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="After" description="%flexunit.after">
<context name="method" />
<attribute name="async"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.async"
/>
<attribute name="ui"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.ui"
/>
<attribute name="order"
type="Number"
required="false"
description="%flexunit.order"
/>
<attribute name="timeout"
type="Number"
required="false"
description="%flexunit.timeout"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="BeforeClass" description="%flexunit.beforeclass">
<context name="method" />
<attribute name="async"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.async"
/>
<attribute name="ui"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.ui"
/>
<attribute name="order"
type="Number"
required="false"
description="%flexunit.order"
/>
<attribute name="timeout"
type="Number"
required="false"
description="%flexunit.timeout"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="AfterClass" description="%flexunit.afterclass">
<context name="method" />
<attribute name="async"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.async"
/>
<attribute name="ui"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.ui"
/>
<attribute name="order"
type="Number"
required="false"
description="%flexunit.order"
/>
<attribute name="timeout"
type="Number"
required="false"
description="%flexunit.timeout"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="Test" description="%flexunit.theory">
<context name="method" />
<attribute name="async"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.async"
/>
<attribute name="ui"
type="Boolean"
required="false"
hint="boolean"
defaultValue="true"
description="%flexunit.ui"
/>
<attribute name="order"
type="Number"
required="false"
description="%flexunit.order"
/>
<attribute name="timeout"
type="Number"
required="false"
description="%flexunit.timeout"
/>
<attribute name="expects"
type="Class"
required="false"
hint="classes"
hintType="Error"
description="%flexunit.expects"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="DataPoint" description="%flexunit.datapoint">
<context name="variable" />
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="DataPoints" description="%flexunit.datapoints">
<context name="variable" type="Array" />
<attribute name="loader"
type="Class"
required="false"
hint="classes"
hintType="org.flexunit.runner.external.IExternalDependencyLoader"
description="%flexunit.loader"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="Parameters" description="%flexunit.parameters">
<context name="method" />
<attribute name="loader"
type="Class"
required="false"
hint="classes"
hintType="org.flexunit.runner.external.IExternalDependencyLoader"
description="%flexunit.loader"
/>
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="RunWith" description="%flexunit.runwith" >
<context name="class" />
<attribute type="Class" required="true" hint="classes" hintType="org.flexunit.runner.IRunner" />
</metadata>
<metadata name="Suite" description="%flexunit.suite" >
<context name="class" />
</metadata>
<metadata name="Ignore" description="%flexunit.ignore" >
<context name="class" />
<context name="method" />
<attribute name="description"
type="String"
required="false"
description="%flexunit.description"
/>
</metadata>
<metadata name="Rule" description="%flexunit.rule" >
<context name="variable" type="org.flexunit.rules.IMethodRule" />
<context name="method" type="org.flexunit.rules.IMethodRule" />
</metadata>

</annotations>