Programmer Tests: Catalog Class

In the previous section, we made the gateways transaction-capable, and the transaction boundary was controlled by the test fixtures. The Catalog class has a dual purpose. On one hand, interface methods of the Catalog class need to manage the transactional boundaries of the application when that class is used by the rest of the application. On the other hand, the Catalog class interface methods need to participate in the transactions managed by programmer tests when the class is being tested. This behavior is similar to what would be achieved by using the transactional serviced components in COM+ that have a Required transaction attribute.

During the execution of the application, the COM+ Enterprise Services run time ...

Get Test-Driven Development in Microsoft® .NET now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.