Esempio n. 1
0
        public void RemoveSubtaskTest()
        {
            // Arrange
            var task = new TaskMother().Build();
            var subTask = new TaskMother().Build();
            task.AddSubtask(subTask);
            var originalCount = task.GetSubtasks().Count();
            var expected = 0;

            // Act
            task.RemoveSubtask(subTask.Id);
            var actual = task.GetSubtasks().Count();

            // Arrange
            Assert.AreEqual(expected, actual);
            Assert.AreNotEqual(originalCount, actual);
        }
Esempio n. 2
0
        public void RemoveInexistentSubtaskShouldFail()
        {
            // Arrange
            var task = new TaskMother().Build();
            var subTask = new TaskMother().Build();

            // Act
            task.RemoveSubtask(subTask.Id);
        }