Ejemplo n.º 1
0
        public void Move_Card_Test()
        {
            IBoardProvider2 boardProvider = new BoardProviderMoc();
            IBoard2 board = new BoardMoc();
            var boardController = new BoardController2(board, boardProvider);
            boardController.On_cards_changed += CardStore.OnCardChanged;

            var cardId = "A";
            boardController.Move_card(cardId, 2);

            var card = CardStore.AllCards().FirstOrDefault(c => c.Id == "A");

            Assert.IsNotNull(card, "card not found");
            Assert.AreEqual(card.ColumnIndex, 2, "columIndex is incorrect");
        }
Ejemplo n.º 2
0
        public void Create_Card_Test()
        {
            IBoardProvider2 boardProvider = new BoardProviderMoc();
            IBoard2 board = new BoardMoc();
            var boardController = new BoardController2(board, boardProvider);
            boardController.On_cards_changed += CardStore.OnCardChanged;

            var cardText = "A new card X";
            boardController.Create_card(cardText, 2);

            var card = CardStore.AllCards().FirstOrDefault(c => c.Text == cardText);

            Assert.IsNotNull(card, "card is not contained");
            Assert.AreEqual(card.ColumnIndex, 2, "columIndex is incorrect");
        }
Ejemplo n.º 3
0
        public void Create_Card_Test()
        {
            IBoardProvider2 boardProvider   = new BoardProviderMoc();
            IBoard2         board           = new BoardMoc();
            var             boardController = new BoardController2(board, boardProvider);

            boardController.On_cards_changed += CardStore.OnCardChanged;

            var cardText = "A new card X";

            boardController.Create_card(cardText, 2);

            var card = CardStore.AllCards().FirstOrDefault(c => c.Text == cardText);

            Assert.IsNotNull(card, "card is not contained");
            Assert.AreEqual(card.ColumnIndex, 2, "columIndex is incorrect");
        }
Ejemplo n.º 4
0
        public void Move_Card_Test()
        {
            IBoardProvider2 boardProvider   = new BoardProviderMoc();
            IBoard2         board           = new BoardMoc();
            var             boardController = new BoardController2(board, boardProvider);

            boardController.On_cards_changed += CardStore.OnCardChanged;

            var cardId = "A";

            boardController.Move_card(cardId, 2);

            var card = CardStore.AllCards().FirstOrDefault(c => c.Id == "A");

            Assert.IsNotNull(card, "card not found");
            Assert.AreEqual(card.ColumnIndex, 2, "columIndex is incorrect");
        }