public void ChangeStrategyTest() { var sw = new Stopwatch(); sw.Start(); var result = simulationService_.Simulate(1000000000, true); Assert.Equal(67, Math.Round(result * 100)); sw.Stop(); testOutputHelper_.WriteLine("Elapsed={0}", sw.Elapsed); }
public SimulationResult Execute([FromBody] SimulationParameters parameters) { var winRate = simulationService_.Simulate( parameters.NumberOfGames, parameters.IsChangeStrategy); return(new SimulationResult { WinRate = winRate }); }
public ActionResult <SimulationResponseModel> Simulate(SimulationRequestModel simulationModelRequest) { return(simulationService.Simulate(simulationModelRequest.ProjectId, simulationModelRequest.ResourceId, simulationModelRequest.StatisticalEngineId, simulationModelRequest.CreatedBy)); }