Пример #1
0
        public StarshipsServiceTests()
        {
            _mocker = new AutoMocker();
            _starshipsRepository = _mocker.GetMock <IStarshipsRepository>();

            _mgltCalculatorService = _mocker.GetMock <IMGLTCalculatorService>();
            _starshipService       = _mocker.CreateInstance <StarshipsService>();
        }
Пример #2
0
        public IntegrationTestsFixture()
        {
            var serviceCollection = new ServiceCollection();

            startup = new StarwarsStartup();
            startup.Config(serviceCollection);

            var serviceProvider = serviceCollection.BuildServiceProvider();

            _starshipService = serviceProvider.GetService <IStarshipsService>();
        }
Пример #3
0
 public StarwarsTests(IntegrationTestsFixture textFixture)
 {
     _test_Fixture    = textFixture;
     _starshipService = _test_Fixture._starshipService;
 }
Пример #4
0
 public StarshipController(IStarshipsService starshipsService)
 {
     _starshipsService = starshipsService;
 }
Пример #5
0
 public StarshipsController(IStarshipsService starshipsService, IPlayersService playersService, UserManager <ApplicationUser> userManager)
 {
     this.starshipsService = starshipsService;
     this.playersService   = playersService;
     this.userManager      = userManager;
 }