07.11.2014 Views

Enterprise Library Test Guide - Willy .Net

Enterprise Library Test Guide - Willy .Net

Enterprise Library Test Guide - Willy .Net

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>Test</strong>ing the <strong>Enterprise</strong> <strong>Library</strong> Core 13<br />

Verifying the <strong>Test</strong> Cases<br />

After you identify all the design test cases, you can verify that the design satisfies<br />

them. Table 3 lists how each of the design test cases were verified for the <strong>Enterprise</strong><br />

<strong>Library</strong> Core.<br />

Table 3: Core Design Verification<br />

Design test case<br />

Verify that the core implements<br />

a base strategy class that<br />

supports the <strong>Enterprise</strong> <strong>Library</strong><br />

strategies and that retrieves<br />

useful information from the<br />

context, such as the configuration<br />

source.<br />

Verify that the core implements<br />

strategy classes that create<br />

objects from the configuration<br />

source and that bind the instrumentation.<br />

Verify that the core implements<br />

base factory classes that create<br />

instance objects and a base factory<br />

class that creates singleton<br />

objects for types that support<br />

them<br />

Verify that the core provides a<br />

façade for a generic object instance<br />

building mechanism that<br />

is based on the ObjectBuilder<br />

subsystem.<br />

Verify that the core implements<br />

configuration watchers that monitor<br />

the configuration sources.<br />

Verify that the core includes<br />

configuration classes that read<br />

various types of configuration<br />

elements such as name, type,<br />

and collection.<br />

Implemented?<br />

Yes<br />

Yes<br />

Yes<br />

Yes<br />

Yes<br />

Yes<br />

Feature that implements design<br />

The <strong>Enterprise</strong><strong>Library</strong>Strategy class derives<br />

from the BuilderStrategy class, which is the<br />

base class for <strong>Enterprise</strong> <strong>Library</strong> strategies. The<br />

<strong>Enterprise</strong><strong>Library</strong>Strategy retrieves the selected<br />

configuration source.<br />

The ConfiguredObjectStrategy class retrieves<br />

the configuration data and creates the objects.<br />

The InstrumentationStrategy class injects the<br />

instrumentation attachment process into the<br />

ObjectBuilder subsystem.<br />

The NameTypeFactoryBase class is a generic<br />

factory class that creates instance objects.<br />

The LocatorNameTypeFactoryBase class is<br />

a generic factory class that creates singleton<br />

object for types that support them.<br />

The <strong>Enterprise</strong><strong>Library</strong>Factory is a façade that<br />

provides the generic building mechanism for the<br />

ObjectBuilder subsystem.<br />

The ConfigurationFileSourceWatcher class<br />

monitors configuration files. Derivations of the<br />

ConfigurationSourceWatcher abstract base<br />

class monitor alternative configuration sources.<br />

The NamedConfigurationElement class represents<br />

a ConfigurationElement object that is a<br />

name element. The NamedElementCollection<br />

class is a generic collection of NamedConfigurationElement<br />

objects. The NameTypeConfigurationElement<br />

class represents a ConfigurationElement<br />

object that has both a name element<br />

and a type element. The NameTypeConfigurationElementCollection<br />

class is a generic collection<br />

of NameTypeConfigurationElement objects.<br />

continued

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!