public void SuccessTest7() { //var scenario = TimeBasedScenario.CreateInstance(_environment); //scenario.NumberOfSteps = 10; //_simulation.AddScenario(scenario); var scenario1 = TaskBasedScenario.CreateInstance(_environment); scenario1.NumberOfTasks = 10; _simulation.AddScenario(scenario1); var scenario2 = MessageBasedScenario.CreateInstance(_environment); scenario2.NumberOfMessages = 10; _simulation.AddScenario(scenario2); SuccessTest(10); }
protected override void SetUpOrganization() { base.SetUpOrganization(); Iterations.Max = ushort.Parse(NumberOfIterations.Text, CultureInfo.InvariantCulture); if (TimeBased.Checked) { var scenario = TimeBasedScenario.CreateInstance(_environment); scenario.NumberOfSteps = ushort.Parse(NumberOfSteps.Text); AddScenario(scenario); } if (TaskBased.Checked) { var scenario = TaskBasedScenario.CreateInstance(_environment); scenario.NumberOfTasks = ushort.Parse(NumberOfTasks.Text, CultureInfo.InvariantCulture); AddScenario(scenario); } if (MessageBased.Checked) { var scenario = MessageBasedScenario.CreateInstance(_environment); scenario.NumberOfMessages = ushort.Parse(NumberOfMessages.Text, CultureInfo.InvariantCulture); AddScenario(scenario); } cbIterations.Items.Clear(); for (var i = 0; i < Iterations.Max; i++) { cbIterations.Items.Add(i); } SetEvents(); #region models if (ModelsOn.Checked) { _mainOrganization.Models.SetOn(1); _mainOrganization.Models.Generator = RandomGenerator.RandomUniform; } else { _mainOrganization.Models.SetOff(); } #endregion #region Murphies if (MurphiesOn.Checked) { _mainOrganization.Murphies.SetOn(1); _mainOrganization.Murphies.IncompleteKnowledge.CommunicationMediums = CommunicationMediums.Email; _mainOrganization.Murphies.IncompleteBelief.CommunicationMediums = CommunicationMediums.Email; } else { _mainOrganization.Murphies.SetOff(); } #endregion SetRandomLevel(cbRandomLevel.SelectedIndex); cbIterations.Enabled = false; _mainOrganization.AddKnowledge(); }