public void ArchiveCurrentTask(string[] commands)
        {
            if (commands.Length != 2)
            {
                throw new BadCommandException(commands);
            }

            string title;

            switch (commands[1])
            {
            case Cat_Done:
                title = manager.ArchiveCurrentTask(Category.Done);
                break;

            case Cat_Cancelled:
                title = manager.ArchiveCurrentTask(Category.Cancelled);
                break;

            case Cat_Obsolete:
                title = manager.ArchiveCurrentTask(Category.Obsolete);
                break;

            default:
                throw new BadCommandException(commands);
            }
            Print($"Task '{title}' is successfully archived ...");
        }
        public void ZTaskManager_ArchiveCurrentTask(int num)
        {
            // Arrange
            foreach (var task in tasks)
            {
                manager.PushTask(task);
            }
            ITask lastTask    = tasks[tasks.Count - 1];
            ITask nthLastTask = tasks[tasks.Count - 1 - num];

            // Assume
            Assume.That(manager.CurrentTask, Is.EqualTo(lastTask));

            // Act
            for (int i = 0; i < num; ++i)
            {
                var t = manager.CurrentTask; // load current task
                manager.ArchiveCurrentTask(Category.Cancelled);
            }

            // Assert
            Assert.That(manager.CurrentTask, Is.EqualTo(nthLastTask));
        }