Ejemplo n.º 1
0
        public void AddFunctionTest()
        {
            #region arrange

            FunctionVO functionVO = new FunctionVO()
            {
                Url = "Role/RoleManagement", Title = "角色管理", Description = "瀏覽角色管理畫面", IsMenu = true, Parent = 0
            };

            int reNumber = 1;

            _dataAccess.Stub(o => o.ExcuteSQL(Arg <string> .Is.Anything, Arg <object[]> .Is.Anything)).Return(reNumber);

            #endregion

            #region act

            var result = _target.AddFunction(functionVO);

            #endregion

            #region assert

            Assert.AreEqual(result, reNumber);

            #endregion
        }