public void CreateGaleShapleyAlgorithm() { GaleShapleyAlgorithm algorithm = new GaleShapleyAlgorithm(Context.StableMarriage); Context.Algorithms.Add(new AlgorithmData { Name = "Gale-Shapley Algoritmus", Algorithm = algorithm, Element = algorithm }); Context.AlgorithmsChanged = true; }
public void RefreshPage() { NewViewModel(); GaleShapleyAlgorithm algorithm = new GaleShapleyAlgorithm(_context.StableMarriage); _context.Algorithms.Add(new AlgorithmData { Name = "test", Algorithm = algorithm, Element = algorithm }); _viewModel.RefreshPage(); Assert.AreEqual(3, _viewModel.Results.Count()); Assert.IsNotNull(_viewModel.Results[2]); Assert.IsTrue(_viewModel.Results[2].Runable); Assert.IsFalse(_viewModel.Results[2].Done); }