private void Awake() { YouLose.gameObject.SetActive(false); InstanceCache.Flush(); gameRepository = InstanceCache.GetOrInstanciate <InMemoryGameRepository>(() => new InMemoryGameRepository()); resultRepository = InstanceCache.GetOrInstanciate <InMemoryResultRepository>(() => new InMemoryResultRepository()); scoreService = InstanceCache.GetOrInstanciate <LocalScoreService>(() => new LocalScoreService()); resultRepository.Clear(); gameRepository.Clear(); scoreService.Reset(); gamePresenter = InstanceCache.GetOrInstanciate <GamePresenter>( () => { resultGenerator = new ResultGenerator(4, new AdditionOperator(), new RandomNumberGenerator(5, 15)); return(new GamePresenter( this, new CreateGame(gameRepository, new FixedInitialNumber(), resultGenerator, resultRepository), new Guess(gameRepository, resultRepository, resultGenerator, scoreService), scoreService)); }); }
public StudentTeacherController(IResultRepository repository, IOptions <MongoSettings> mongoSettings = null) { var _mongoSettings = mongoSettings.Value; _context = new ApplicationContext(_mongoSettings); _results = repository; }
public void Initialize() { BaseSqlTests.SeedDatabase(); _studentRepository = new StudentRepository(); _resultRepository = new ResultRepository(); _service = new StudentService(_studentRepository, _resultRepository); }
/// <summary> /// Create a new TestViewer /// </summary> /// <param name="resultRepository">the ResultRepository</param> /// <param name="testsystemRepository">the TestsystemRepository</param> /// <param name="testsuiteRepository">the TestsuiteRepository</param> /// <param name="testerRepository">the TesterRepository</param> /// <param name="testcaseRepository">the TestcaseRepository</param> /// <param name="historyResultRepository">the HistoryResultRepository</param> public TestViewerService(IResultRepository resultRepository, ITestsystemRepository testsystemRepository, ITestsuiteRepository testsuiteRepository, ITesterRepository testerRepository, ITestcaseRepository testcaseRepository, IHistoryResultRepository historyResultRepository) { if (resultRepository == null) { throw new ArgumentNullException("resultRepository"); } if (testsystemRepository == null) { throw new ArgumentNullException("testsystemRepository"); } if (testsuiteRepository == null) { throw new ArgumentNullException("testsuiteRepository"); } if (testerRepository == null) { throw new ArgumentNullException("testerRepository"); } if (testcaseRepository == null) { throw new ArgumentNullException("testcaseRepository"); } if (historyResultRepository == null) { throw new ArgumentNullException("historyResultRepository"); } _resultRepository = resultRepository; _testsystemRepository = testsystemRepository; _testsuiteRepository = testsuiteRepository; _testerRepository = testerRepository; _testcaseRepository = testcaseRepository; _historyResultRepository = historyResultRepository; }
public UserService(IMapper mapper, IUserRepository userRepository, IResultRepository resultRepository, UserManager <User> userManager) { _mapper = mapper; _userRepository = userRepository; _resultRepository = resultRepository; _userManager = userManager; }
/// <summary> /// Create a new nodeService /// </summary> /// <param name="testPool">the testPool</param> /// <param name="testFileLocker">the testFileLocker</param> /// <param name="resultRepository">the resultRepository</param> /// <param name="historyResultRepository">the historyResultRepository</param> /// <param name="browserRepository">the browserRepository</param> public NodeService(ITestPool testPool, ITestFileLocker testFileLocker, IResultRepository resultRepository, IHistoryResultRepository historyResultRepository, IBrowserRepository browserRepository) { if (testPool == null) { throw new ArgumentNullException("testPool"); } if (testFileLocker == null) { throw new ArgumentNullException("testFileLocker"); } if (resultRepository == null) { throw new ArgumentNullException("resultRepository"); } if (historyResultRepository == null) { throw new ArgumentNullException("historyResultRepository"); } if (browserRepository == null) { throw new ArgumentNullException("browserRepository"); } _testPool = testPool; _testFileLocker = testFileLocker; _resultRepository = resultRepository; _historyResultRepository = historyResultRepository; _browserRepository = browserRepository; }
public ResultService(IResultRepository resultRepository, IAccountInfoRepository accountInfoRepository, IResultModelMapper resultMapper, IResultAccountModelMapper resultAccountModelMapper) { _resultRepository = resultRepository; _resultAccountModelMapper = resultAccountModelMapper; _resultMapper = resultMapper; _accountInfoRepository = accountInfoRepository; }
public HomeController(IAlgorithm algorithm, IArrayRepository arrayRepository, IParametersRepository parametersRepository, IResultRepository resultRepository) { Algorithm = algorithm; _arrayRepository = arrayRepository; _parametersRepository = parametersRepository; _resultRepository = resultRepository; }
public void Initialize() { BaseSqlTests.SeedDatabase(); _repository = new EvaluationRepository(); _resultRepository = new ResultRepository(); _service = new EvaluationService(_repository, _resultRepository); }
/// <summary> /// Create a new testPool /// </summary> /// <param name="testJobRepository">the testJobRepository</param> /// <param name="resultRepository">the resultRepository</param> /// <param name="testFileLocker">the testFileLocker</param> /// <param name="testJobFinishedMail">mail notification on testsuite finished.</param> public TestPool(ITestJobRepository testJobRepository, IResultRepository resultRepository, ITestFileLocker testFileLocker, ITestJobFinishedMail testJobFinishedMail) { if (testJobRepository == null) { throw new ArgumentNullException("testJobRepository"); } if (resultRepository == null) { throw new ArgumentNullException("resultRepository"); } if (testFileLocker == null) { throw new ArgumentNullException("testFileLocker"); } _resultRepository = resultRepository; _testFileLocker = testFileLocker; _testJobFinishedMail = testJobFinishedMail; _waitingWorkItems = new List <WorkItem>(); _currentWorkItems = new List <WorkItem>(); _currentTestJobManagers = new List <ITestJobManager>(); _testWorkers = new Dictionary <string, ITestWorker>(); _testJobRepository = testJobRepository; }
public ClassroomProcessor(IClassroomRepository classroomRepository, IMapper mapper, IUserRepository userRepository, IResultRepository resultRepository) { _classroomRepository = classroomRepository; _mapper = mapper; _userRepository = userRepository; _resultRepository = resultRepository; }
public CalculatorViewModel(IMathRepository mathRepository, IResultRepository resultRepository, IDialogPlugin dialogPlugin, ILogger logger) { _mathRepository = mathRepository; _resultRepository = resultRepository; _dialogPlugin = dialogPlugin; _logger = logger; }
/// <summary> /// Creates a new TestManager /// </summary> /// <param name="testPool">the testPool</param> /// <param name="testsuiteRepository">the testsuiteRepository</param> /// <param name="testsystemRepository">the testsystemRepository</param> /// <param name="testerRepository">the testerRepository</param> /// <param name="resultRepository">the resultRepository</param> public TestService(ITestPool testPool, ITestsuiteRepository testsuiteRepository, ITestsystemRepository testsystemRepository, ITesterRepository testerRepository, IResultRepository resultRepository) { if (testsuiteRepository == null) { throw new ArgumentNullException("testsuiteRepository"); } if (testsystemRepository == null) { throw new ArgumentNullException("testsystemRepository"); } if (testerRepository == null) { throw new ArgumentNullException("testerRepository"); } if (resultRepository == null) { throw new ArgumentNullException("resultRepository"); } _testPool = testPool; _testsuiteRepository = testsuiteRepository; _testsystemRepository = testsystemRepository; _testerRepository = testerRepository; _resultRepository = resultRepository; }
public HomeController(IPartyRepository partyRepository, IModuleRepository moduleRepository, IResultRepository resultRepository, IVoteRepository voteRepository) { _partyRepository = partyRepository; _moduleRepository = moduleRepository; _resultRepository = resultRepository; _voteRepository = voteRepository; }
public HomeController(AntAlgorithm.Algorithm.StandartAlgoritmBuilder algorithm, IArrayRepository arrayRepository, IParametersRepository parametersRepository, IResultRepository resultRepository) { Algorithm = algorithm.GetAlgorithm(0.5, 0.5, 100, 20); _arrayRepository = arrayRepository; _parametersRepository = parametersRepository; _resultRepository = resultRepository; }
public SessionProcessor(ISessionRepository sessionRepository, IClassroomRepository classRoomRepo, IResultRepository resultRepo, IUserRepository userRepository, IMapper mapper) { _sessionRepository = sessionRepository; _classRoomRepo = classRoomRepo; _resultRepo = resultRepo; _userRepository = userRepository; _mapper = mapper; }
public ResultController( IResultRepository _resultRepository, IResultTypeRepository _resultTypeRepository ) { ResultRepository = _resultRepository; ResultTypeRepository = _resultTypeRepository; }
public void Initialize() { BaseSqlTests.SeedDatabase(); _repository = new ResultRepository(); _service = new ResultService(_repository); _student = ObjectMother.GetExistentValidStudent(); _evaluation = ObjectMother.GetExistentValidEvaluation(); }
public ResultService(IRepository <AssessmentSeries> assessmentSeriesRepository, IRepository <TlLookup> tlLookupRepository, IResultRepository resultRepository, IRepository <TqPathwayResult> pathwayResultRepository, IMapper mapper, ILogger <ResultService> logger) { _assessmentSeriesRepository = assessmentSeriesRepository; _tlLookupRepository = tlLookupRepository; _resultRepository = resultRepository; _pathwayResultRepository = pathwayResultRepository; _mapper = mapper; _logger = logger; }
public TestRunnerOptions(bool silent, IResultRepository resultRepository, TimeSpan frequency, int maxRuns, bool hideResults, CancellationToken cancellationToken) { Silent = silent; ResultRepository = resultRepository; Frequency = frequency; MaxRuns = maxRuns; HideResults = hideResults; CancellationToken = cancellationToken; }
public TestController(ITaskRepository taskRepository, ICodeRepository codeRepository, IResultRepository resultRepository, IUserRepository userRepository, IAllCodeRepository allCodeRepository) { _taskRepository = taskRepository; _codeRepository = codeRepository; _resultRepository = resultRepository; _userRepository = userRepository; _allCodeRepository = allCodeRepository; }
public ResultService(IMapper mapper, IResultRepository resultRepository, ITestRepository testRepository, IUserRepository userRepository) { _mapper = mapper; _resultRepository = resultRepository; _testRepository = testRepository; _userRepository = userRepository; }
public RMAMobileController(IPartyRepository partyRepository, IModuleRepository moduleRepository, IResultRepository resultRepository, IVoteRepository voteRepository) { _partyRepository = partyRepository; _moduleRepository = moduleRepository; _resultRepository = resultRepository; _voteRepository = voteRepository; //UserManager = userManager; //SignInManager = signInManager; }
public CreateGame(GameRepository gameRepository, InitialNumberGenerator initialNumberGenerator, ResultGenerator resultGenerator, IResultRepository resultRepository) { this.gameRepository = gameRepository; this.initialNumberGenerator = initialNumberGenerator; this.resultGenerator = resultGenerator; this.resultRepository = resultRepository; }
public Guess(GameRepository gameRepository, IResultRepository resultRepository, ResultGenerator resultGenerator, ScoreService scoreService) { this.gameRepository = gameRepository; this.resultRepository = resultRepository; this.resultGenerator = resultGenerator; this.scoreService = scoreService; }
public EvaluationUOW(EvaluationContext context, EvIdentityContext identContext, UserManager <EvaluationUser> appUserManager, IUserRepository userRepository, IResultRepository resultRepository, IQuestionRepository questionRepository, ITestRepository testRepository) { _context = context ?? throw new ArgumentNullException(nameof(context)); _identContext = identContext ?? throw new ArgumentNullException(nameof(identContext)); _appUserManager = appUserManager ?? throw new ArgumentNullException(nameof(appUserManager)); users = userRepository ?? throw new ArgumentNullException(nameof(appUserManager)); results = resultRepository ?? throw new ArgumentNullException(nameof(appUserManager)); questions = questionRepository ?? throw new ArgumentNullException(nameof(appUserManager)); tests = testRepository ?? throw new ArgumentNullException(nameof(appUserManager)); }
public ExamAnswersController(IAppUserGroupMemberRepository appUserGroupMemberRepository, IExamRepository examRepository, IResultRepository resultRepository, IGroupMemberRepository groupMemberRepository, IGroupRepository groupRepository) { _groupRepository = groupRepository; _groupMemberRepository = groupMemberRepository; _examRepository = examRepository; _resultRepository = resultRepository; _appUserGroupMemberRepository = appUserGroupMemberRepository; }
public UnitOfWork(DbContext context, ITestRepository testRepository, IUserAnswerRepository userAnswerRepository, IResultRepository resultRepository, IQuestionRepository questionRrepository, IQuestionAnswerRepository questionAnswerRepository) { Context = context; this.TestRepository = testRepository; this.ResultRepository = resultRepository; this.UserAnswerRepository = userAnswerRepository; this.QuestionRrepository = questionRrepository; this.QuestionAnswerRepository = questionAnswerRepository; }
public ElectionService(IElectionRepository electionRepository, IElectionCandidateRepository electionCandidateRepository, IElectionCitizenRepository electionCitizenRepository, IElectionPoliticPartyRepository electionPoliticPartyRepository, IElectionPositionRepository electionPositionRepository, IResultRepository resultRepository) { _electionRepository = electionRepository; _electionCandidateRepository = electionCandidateRepository; _electionCitizenRepository = electionCitizenRepository; _electionPoliticPartyRepository = electionPoliticPartyRepository; _electionPositionRepository = electionPositionRepository; _resultRepository = resultRepository; }
public AdminController(IUserRepository usrepo, IQuestionRepository quesrepo, IEvntRepository evrepo, IAnswerRepository ansrepo, ICourseRepository currepo, IExamRepository exrepo, IOptionRepository oprepo, IRegistrationRepository regrepo, IResultRepository resrepo) { this.evrepo = evrepo; this.usrepo = usrepo; this.quesrepo = quesrepo; this.ansrepo = ansrepo; this.currepo = currepo; this.exrepo = exrepo; this.oprepo = oprepo; this.regrepo = regrepo; this.resrepo = resrepo; }
public HomeController( ILogger <HomeController> logger, IPaperAnalyzerService analyzeService, IResultRepository repository, IOptions <MongoSettings> mongoSettings = null) { MongoSettings = mongoSettings?.Value; Repository = repository; _context = new ApplicationContext(MongoSettings); _logger = logger; _analyzeService = analyzeService; }
public TestService(IMapper mapper, ITestRepository testRepository, IQuestionRepository questionRepository, IUserRepository userRepository, IResultRepository resultRepository) { _mapper = mapper; _testRepository = testRepository; _questionRepository = questionRepository; _userRepository = userRepository; _resultRepository = resultRepository; }
/// <summary> /// Create a new SummaryService /// </summary> /// <param name="resultRepository">the ResultRepository</param> /// <param name="testsystemRepository">the TestsystemRepository</param> /// <param name="testsuiteRepository">the TestsuiteRepository</param> /// <param name="testJobRepository">the TestJobRepository</param> public SummaryService(IResultRepository resultRepository, ITestsystemRepository testsystemRepository, ITestsuiteRepository testsuiteRepository, ITestJobRepository testJobRepository) { if (resultRepository == null) throw new ArgumentNullException("resultRepository"); if (testsystemRepository == null) throw new ArgumentNullException("testsystemRepository"); if (testsuiteRepository == null) throw new ArgumentNullException("testsuiteRepository"); if (testJobRepository == null) throw new ArgumentNullException("testJobRepository"); _resultRepository = resultRepository; _testsystemRepository = testsystemRepository; _testsuiteRepository = testsuiteRepository; _testJobRepository = testJobRepository; }
/// <summary> /// Create a new nodeService /// </summary> /// <param name="testPool">the testPool</param> /// <param name="testFileLocker">the testFileLocker</param> /// <param name="resultRepository">the resultRepository</param> /// <param name="historyResultRepository">the historyResultRepository</param> /// <param name="browserRepository">the browserRepository</param> public NodeService(ITestPool testPool, ITestFileLocker testFileLocker, IResultRepository resultRepository, IHistoryResultRepository historyResultRepository, IBrowserRepository browserRepository) { if (testPool == null) throw new ArgumentNullException("testPool"); if (testFileLocker == null) throw new ArgumentNullException("testFileLocker"); if (resultRepository == null) throw new ArgumentNullException("resultRepository"); if (historyResultRepository == null) throw new ArgumentNullException("historyResultRepository"); if (browserRepository == null) throw new ArgumentNullException("browserRepository"); _testPool = testPool; _testFileLocker = testFileLocker; _resultRepository = resultRepository; _historyResultRepository = historyResultRepository; _browserRepository = browserRepository; }
/// <summary> /// Creates a new TestManager /// </summary> /// <param name="testPool">the testPool</param> /// <param name="testsuiteRepository">the testsuiteRepository</param> /// <param name="testsystemRepository">the testsystemRepository</param> /// <param name="testerRepository">the testerRepository</param> /// <param name="resultRepository">the resultRepository</param> public TestService(ITestPool testPool, ITestsuiteRepository testsuiteRepository, ITestsystemRepository testsystemRepository, ITesterRepository testerRepository, IResultRepository resultRepository) { if (testsuiteRepository == null) throw new ArgumentNullException("testsuiteRepository"); if (testsystemRepository == null) throw new ArgumentNullException("testsystemRepository"); if (testerRepository == null) throw new ArgumentNullException("testerRepository"); if (resultRepository == null) throw new ArgumentNullException("resultRepository"); _testPool = testPool; _testsuiteRepository = testsuiteRepository; _testsystemRepository = testsystemRepository; _testerRepository = testerRepository; _resultRepository = resultRepository; }
/// <summary> /// Create a new testPool /// </summary> /// <param name="testJobRepository">the testJobRepository</param> /// <param name="resultRepository">the resultRepository</param> /// <param name="testFileLocker">the testFileLocker</param> /// <param name="testJobFinishedMail">mail notification on testsuite finished.</param> public TestPool(ITestJobRepository testJobRepository, IResultRepository resultRepository, ITestFileLocker testFileLocker, ITestJobFinishedMail testJobFinishedMail) { if (testJobRepository == null) throw new ArgumentNullException("testJobRepository"); if (resultRepository == null) throw new ArgumentNullException("resultRepository"); if (testFileLocker == null) throw new ArgumentNullException("testFileLocker"); _resultRepository = resultRepository; _testFileLocker = testFileLocker; _testJobFinishedMail = testJobFinishedMail; _waitingWorkItems = new List<WorkItem>(); _currentWorkItems = new List<WorkItem>(); _currentTestJobManagers = new List<ITestJobManager>(); _testWorkers = new Dictionary<string, ITestWorker>(); _testJobRepository = testJobRepository; }
/// <summary> /// Create a new TestViewer /// </summary> /// <param name="resultRepository">the ResultRepository</param> /// <param name="testsystemRepository">the TestsystemRepository</param> /// <param name="testsuiteRepository">the TestsuiteRepository</param> /// <param name="testerRepository">the TesterRepository</param> /// <param name="testcaseRepository">the TestcaseRepository</param> /// <param name="historyResultRepository">the HistoryResultRepository</param> public TestViewerService(IResultRepository resultRepository, ITestsystemRepository testsystemRepository, ITestsuiteRepository testsuiteRepository, ITesterRepository testerRepository, ITestcaseRepository testcaseRepository, IHistoryResultRepository historyResultRepository) { if (resultRepository == null) throw new ArgumentNullException("resultRepository"); if (testsystemRepository == null) throw new ArgumentNullException("testsystemRepository"); if (testsuiteRepository == null) throw new ArgumentNullException("testsuiteRepository"); if (testerRepository == null) throw new ArgumentNullException("testerRepository"); if (testcaseRepository == null) throw new ArgumentNullException("testcaseRepository"); if (historyResultRepository == null) throw new ArgumentNullException("historyResultRepository"); _resultRepository = resultRepository; _testsystemRepository = testsystemRepository; _testsuiteRepository = testsuiteRepository; _testerRepository = testerRepository; _testcaseRepository = testcaseRepository; _historyResultRepository = historyResultRepository; }
public void AfterEach() { this.repository = null; }
public void BeforeEach() { this.repository = this.GetRepository(); }