コード例 #1
0
        public void Update_TestCase9()
        {
            LuonCongViecDAO dao          = new LuonCongViecDAO();
            LUONCONGVIEC    luonCongViec = new LUONCONGVIEC
            {
                MaHoSo      = TestCommon.LEN_10,
                NodeHienTai = "12345",
                TiepNhan    = false,
                KhamBenh    = false,
                XetNghiem   = false
            };

            dao.Save(db, luonCongViec);
            LUONCONGVIEC luonCongViecUpdate = new LUONCONGVIEC
            {
                MaHoSo      = "1234",
                NodeHienTai = "12345",
                TiepNhan    = false,
                KhamBenh    = true,
                XetNghiem   = true
            };
            string actual = dao.Save(db, luonCongViecUpdate);
            // Biến kết quả
            string expected = "1111";

            // Test
            Assert.Equals(expected, actual);
        }
コード例 #2
0
        public void Insert_TestCase2()
        {
            LUONCONGVIEC luonCongViec = new LUONCONGVIEC
            {
                NodeHienTai = "12345",
                TiepNhan    = true,
                KhamBenh    = true,
                XetNghiem   = true
            };
            LuonCongViecDAO dao      = new LuonCongViecDAO();
            string          actual   = dao.Save(db, luonCongViec);
            string          expected = "1111";

            Assert.Equals(expected, actual);
        }
コード例 #3
0
        public void Delete_TestCase10()
        {
            LUONCONGVIEC luonCongViec = new LUONCONGVIEC
            {
                MaHoSo      = TestCommon.LEN_10,
                NodeHienTai = "12345",
                TiepNhan    = true,
                KhamBenh    = true,
                XetNghiem   = true
            };
            LuonCongViecDAO dao    = new LuonCongViecDAO();
            string          actual = dao.Save(db, luonCongViec);

            Assert.Equals(null, actual);
        }
コード例 #4
0
        public void Update_TestCase8()
        {
            LuonCongViecDAO dao          = new LuonCongViecDAO();
            LUONCONGVIEC    luonCongViec = new LUONCONGVIEC
            {
                MaHoSo      = TestCommon.LEN_10,
                NodeHienTai = "12345",
            };

            dao.Save(db, luonCongViec);
            LUONCONGVIEC luonCongViecUpdate = new LUONCONGVIEC
            {
                MaHoSo      = TestCommon.LEN_10 + "1",
                NodeHienTai = "123456",
            };
            string actual = dao.Save(db, luonCongViecUpdate);
            // Biến kết quả
            string expected = "1111";

            // Test
            Assert.Equals(expected, actual);
        }
コード例 #5
0
 public LuonCongViecBUS()
 {
     luonCongViecService = new LuonCongViecDAO();
 }