The Gallio.Framework.Pattern namespace provides the Pattern Test Framework which can serve as the foundation for building new test frameworks.

Classes

  ClassDescription
AnnotationPatternAttribute
Associates an annotation message with a code element. When the code element is processed as part of building some other test, the annotation message will be emitted. This may be used to signal error, warning, and informational messages associated with the code element in question.
BaseBuilder
Abstract base class for typical builder implementations.
BasePattern
Abstract base implementation of IPattern with do-nothing implementations.
BaseTestComponentBuilder
Abstract base class for test component builders.
ContributionMethodPatternAttribute
A contribution method pattern attribute applies decorations to a containing scope such as by introducing a new setup or teardown action to a test.
DataPatternAttribute
The data pattern attribute applies a data source to a fixture or test parameter declaratively.
DeclarativePatternResolver
A declarative pattern resolver based on PatternAttribute.
DecoratorPatternAttribute
A decorator attribute applies contributions to a test component in scope such as a test or test parameter generated by some other pattern attribute.
DefaultPatternEvaluator
Default implementation of a pattern evaluator.
DefaultPatternScope
Default implementation of a pattern scope.
DefaultTestBuilder
Default implementation of a test model builder.
DefaultTestDataContextBuilder
Default implementation of a test data context builder.
DefaultTestModelBuilder
Default implementation of a test model builder.
DefaultTestParameterBuilder
Default implementation of a test parameter builder.
FixtureMemberInvoker<(Of <(TOutput>)>)
Finds and invokes a member of a test fixture, a nested type of the test fixture, or an external type.
MetadataPatternAttribute
Applies declarative metadata to a test component.
PatternAttribute
The PatternAttribute class is the base class for all pattern test framework attributes. It associates a code element with a IPattern for building up parts of the test model using reflection.
PatternAttributeTargets
Standard AttributeTargets flag combinations for PatternAttribute declarations.
PatternTest
A test case that has been defined by the PatternTestFramework.
PatternTestActions
Pattern test action provide the logic that implements the various phases of the test execution lifecycle.
PatternTestController
Controls the execution of PatternTest instances.
PatternTestDataContext
A pattern test data context introduces a scope for data source declarations.
PatternTestFramework
The pattern test framework is a built-in framework that Gallio provides based on reflection over attributes that implement IPattern.
PatternTestFrameworkExtensionInfo
Provides information about a particular pattern test framework extension.
PatternTestInstanceActions
Pattern test instance actions provide the logic that implements the various phases of the test instance execution lifecycle.
PatternTestInstanceState
Represents the run-time state of a single instance of a PatternTest that is to be executed.
PatternTestModel
The test model for the pattern test framework.
PatternTestParameter
Represents an parameter of a PatternTest derived from a field, property or method parameter.
PatternTestParameterActions

An implementation of IPatternTestParameterHandler based on actions that can be sequenced and composed as chains.

PatternTestState
Represents the run-time state of a PatternTest that is to be executed.
PatternTestStep
A step that belongs to a PatternTest.
PatternUsageErrorException
The type of exception thrown when a test declaration is malformed or contains an error.
ProcessIsolation
The process isolation object saves global process-level context information when it is created and restores it when it is disposed.
ReflectionOnlyTestModelBuilder
An implementation of a test model builder that is used for reflection only and does not actually support building tests.
TestAssemblyDecoratorPatternAttribute
A test assembly decorator pattern attribute applies decorations to an existing test declared at the assembly-level.
TestAssemblyExecutionParameters
Configures runtime parameters while executing tests within a test assembly.
TestAssemblyInitializationAttribute
An assembly initialization attribute gets a chance to perform early initialization of the system before enumerating the tests within the assembly.
TestAssemblyPatternAttribute
Declares that an assembly generates an assembly-level test.
TestConstructorPatternAttribute
Declares that a constructor is used to provide test fixture parameters.
TestDecoratorPatternAttribute
A test decorator pattern attribute applies decorations to a test defined by an assembly, type, or method.
TestDependencyPatternAttribute
A dependency pattern attribute creates a dependency on the tests defined by some other code element.
TestMethodDecoratorPatternAttribute
A test decorator pattern attribute applies decorations to an existing test declared at the method-level.
TestMethodPatternAttribute
Declares that a method represents a test.
TestParameterDecoratorPatternAttribute
A test parameter decorator pattern attribute applies decorations to an existing PatternTestParameter.
TestParameterPatternAttribute
Declares that a field, property, method parameter or generic parameter represents a PatternTestParameter.
TestTypeDecoratorPatternAttribute
A test type decorator pattern attribute applies decorations to an existing test declared at the type-level.
TestTypePatternAttribute
Declares that a type represents a test.

Interfaces

  InterfaceDescription
IPattern
A IPattern defines a composable rule for building up a test model using reflection.
IPatternEvaluator
A pattern evaluator maintains state that is needed to interpret patterns.
IPatternResolver
The pattern resolver provides a means for obtaining the IPattern objects associated with an ICodeElementInfo.
IPatternScope
A pattern scope describes the environment in which the pattern is being evaluated.
IPatternTestComponent
An interface shared by PatternTest and PatternTestParameter.
IPatternTestParameterHandler
A pattern test parameter handler provides the logic that implements the various phases of the test parameter binding lifecycle.
ISupportDeferredActions
Provides support for performing deferred build actions.
ITestBuilder
A test builder applies contributions to a test under construction.
ITestComponentBuilder
A test component builder applies contributions to a test or test parameter under construction.
ITestDataContextBuilder
A test data context builder applies contributions to a test data context under construction.
ITestModelBuilder
A test model builder applies contributions to a test model under construction.
ITestParameterBuilder
A test builder applies contributions to a test under construction.

Delegates

  DelegateDescription
DeferredComponentPopulator
Populates components lazily.
PatternTestPopulator
A delegate used to lazily populate the children of an PatternTest.
TestAction
Performs one primitive action of a test and returns its outcome.

Enumerations

  EnumerationDescription
FixtureMemberInvokerTargets
Targeted member types for the fixture invoker.

Remarks

The Pattern Test Framework is based on the idea of extensible and composable units called patterns (IPattern). Patterns are usually encoded as .Net attributes and applied to test assemblies, types and members to define tests.

MbUnit is based on the Pattern Test Framework.

If you are implementing a new attribute-based test framework then you may find it beneficial to extend the Pattern Test Framework. Alternately you may implement ITestFramework directly.

See Also