Exemplo n.º 1
0
        public void TheInputTest()
        {
            PyramidService          pyramidService = new PyramidService();
            Dictionary <int, int[]> piramid        = Mocks.GetTheInputMock();
            MyDictionary            theWay         = new MyDictionary();

            try
            {
                pyramidService.getPosibleWays(ref piramid, null, ref theWay);
            }
            catch (Exception ex)
            {
                Assert.Fail(ex.Message);
            }
            Assert.IsTrue(theWay.GetPath() == "215, 192, 269, 836, 805, 728, 433, 528, 863, 632, 931, 778, 413, 310, 253");
        }
Exemplo n.º 2
0
        public void SimpleInputTest()
        {
            PyramidService          pyramidService = new PyramidService();
            Dictionary <int, int[]> piramid        = Mocks.GetSimpleInputMock();
            MyDictionary            theWay         = new MyDictionary();

            try
            {
                pyramidService.getPosibleWays(ref piramid, null, ref theWay);
            }
            catch (Exception ex)
            {
                Assert.Fail(ex.Message);
            }
            Assert.IsTrue(theWay.GetPath() == "1, 8, 5, 2");
        }