/Source/Bifrost.Specs/Execution/for_TypeDiscoverer/when_finding_types_with_only_one_implementation.cs

# · C# · 16 lines · 14 code · 2 blank · 0 comment · 0 complexity · fb37eaaff2bac242c4bf5aebf3bde85a MD5 · raw file

  1. using System;
  2. using Bifrost.Execution;
  3. using Machine.Specifications;
  4. namespace Bifrost.Specs.Execution.for_TypeDiscoverer
  5. {
  6. [Subject(typeof(TypeDiscoverer))]
  7. public class when_finding_types_with_only_one_implementation : given.a_type_discoverer
  8. {
  9. static Type typeFound;
  10. Because we_find_single = () => typeFound = TypeDiscoverer.FindSingle<ISingle>();
  11. It should_not_return_null = () => typeFound.ShouldNotBeNull();
  12. It should_return_correct_implementation_when = () => typeFound.ShouldEqual(typeof (Single));
  13. }
  14. }