diff options
| author | mo khan <mo@mokhan.ca> | 2009-05-25 07:45:49 -0600 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2009-05-25 07:45:49 -0600 |
| commit | 37270a3e121682e6f9bbd76a609dcc70daf1d911 (patch) | |
| tree | 67d8db5a782e7c934d632c50d637300266966659 | |
| parent | b1070dd31ddb1497a1f7c4a4c76feab15406fc79 (diff) | |
pruning dead code
| -rw-r--r-- | product/project.specifications/MockingExtensions.cs | 26 | ||||
| -rw-r--r-- | product/project.specifications/project.specifications.csproj | 1 |
2 files changed, 5 insertions, 22 deletions
diff --git a/product/project.specifications/MockingExtensions.cs b/product/project.specifications/MockingExtensions.cs index 6fc5eb1..2a65a86 100644 --- a/product/project.specifications/MockingExtensions.cs +++ b/product/project.specifications/MockingExtensions.cs @@ -1,4 +1,3 @@ -using System; using System.Collections.Generic; using System.Linq; using Rhino.Mocks; @@ -6,38 +5,23 @@ using Rhino.Mocks.Interfaces; namespace specifications { - public static class MockingExtensions + static public class MockingExtensions { - public static IMethodOptions<R> is_told_to<T, R>(this T mocked_item, Function<T, R> action_to_perform) where T : class + static public IMethodOptions<R> is_told_to<T, R>(this T mocked_item, Function<T, R> action_to_perform) + where T : class { return mocked_item.Stub(action_to_perform); } - public static IMethodOptions<R> is_asked_for<T, R>(this T mock, Function<T, R> func) where T : class - { - return mock.Stub(func); - } - - public static IMethodOptions<R> it_will_return<R>(this IMethodOptions<R> options, R item) + static public IMethodOptions<R> it_will_return<R>(this IMethodOptions<R> options, R item) { return options.Return(item); } - public static IMethodOptions<IEnumerable<R>> it_will_return<R>(this IMethodOptions<IEnumerable<R>> options, + static public IMethodOptions<IEnumerable<R>> it_will_return<R>(this IMethodOptions<IEnumerable<R>> options, params R[] items) { return options.Return(items.AsEnumerable()); } - - public static IMethodOptions<IEnumerable<R>> it_will_return_nothing<R>( - this IMethodOptions<IEnumerable<R>> options) - { - return options.it_will_return(); - } - - public static void it_will_throw<R>(this IMethodOptions<R> options, Exception item) - { - options.Throw(item); - } } }
\ No newline at end of file diff --git a/product/project.specifications/project.specifications.csproj b/product/project.specifications/project.specifications.csproj index 7b911ce..5d0e06f 100644 --- a/product/project.specifications/project.specifications.csproj +++ b/product/project.specifications/project.specifications.csproj @@ -73,7 +73,6 @@ <Compile Include="domain\MarsSpecs.cs" /> <Compile Include="MockingExtensions.cs" /> <Compile Include="presentation\CaptureUserInstructionsPresenterSpecs.cs" /> - <Compile Include="domain\PositionSpecs.cs" /> <Compile Include="presentation\infrastructure\CommandFactorySpecs.cs" /> <Compile Include="presentation\infrastructure\SynchronousCommandProcessorSpecs.cs" /> <Compile Include="presentation\infrastructure\SynchronousCommandPumpSpecs.cs" /> |
