예제 #1
0
 public CruiseService(InjectionTest injectionTest, SimpleLogicTest simpleLogicTest, XMLTest xMLTest, WebTest webTest)
 {
     _injectionTest   = injectionTest;
     _simpleLogicTest = simpleLogicTest;
     _xMLTest         = xMLTest;
     _webTest         = webTest;
 }
예제 #2
0
 public TestsService(WebTest webTest, XMLTest xMLTest, SimpleLogicTest simpleLogicTest, InjectionTest injectionTest)
 {
     _webTest         = webTest;
     _xMLTest         = xMLTest;
     _simpleLogicTest = simpleLogicTest;
     _injectionTest   = injectionTest;
 }
예제 #3
0
        public ActionResult <List <CruiseDTO> > Get(CruiseRequestDTO id)
        {
            InjectionTest injection = new InjectionTest();

            return(injection.GetCruises(id));

            //var webtests = new WebTest();
            //return webtests.GetAllMovies();
            //return "value";
        }
예제 #4
0
        public void InjectionServiceInjectsInstanceDependencies()
        {
            InjectionTest injectionTest = new InjectionTest();

            Assert.That(injectionTest.EventService, Is.Null);
            Assert.That(injectionTest.HookService, Is.Null);
            Assert.That(injectionTest.InjectionTestService, Is.Null);

            InjectionService !.Inject(injectionTest);

            Assert.That(injectionTest.EventService, Is.Not.Null);
            Assert.That(injectionTest.HookService, Is.Not.Null);
            Assert.That(injectionTest.InjectionTestService, Is.Not.Null);
        }
예제 #5
0
 public void CheckInjectionTest1()
 {
     InjectionTest test = new InjectionTest(new ConcreteMember());
     Action action = () =>
     {
         Check.InjectedMembers(test);
     };
     action.ShouldNotThrow();
 }
예제 #6
0
 public void CheckInjectionTest()
 {
     InjectionTest test = new InjectionTest(null);
     Assert.Throws<InvalidOperationException>(() => Check.InjectedMembers(test));
 }
예제 #7
0
 public CruisesController()
 {
     this._injectionTest = new InjectionTest();
 }