Table of Contents

Class ProxyDemo.MockFramework

Namespace
PatternKit.Examples.ProxyDemo
Assembly
PatternKit.Examples.dll

A simple fluent mocking framework built with the Proxy pattern.

public static class ProxyDemo.MockFramework
Inheritance
ProxyDemo.MockFramework
Inherited Members

Remarks

This demonstrates how proxy patterns power testing frameworks like Moq and NSubstitute. The mock intercepts calls, records invocations, and returns configured values.

Methods

CreateMock<TIn, TOut>()

Creates a new mock instance.

public static ProxyDemo.MockFramework.Mock<TIn, TOut> CreateMock<TIn, TOut>() where TIn : notnull

Returns

ProxyDemo.MockFramework.Mock<TIn, TOut>

A new mock builder.

Type Parameters

TIn

The input type.

TOut

The output type.