private void btnTimKiem_Click(object sender, EventArgs e) { grcBase.DataSource = DMChucVuDataProvider.Search(new DMChucVuInfor { MaChucVu = txtTimKiemMa.Text.Trim(), TenChucVu = txtTimKiemTen.Text.Trim() }); }
public void TestChucVu05_InsertSuccess() { frmDM_ChucVu frm = new frmDM_ChucVu(); frm.Oid = 0; frm.isAdd = true; frmChiTiet_ChucVu frmChiTietChucVu = new frmChiTiet_ChucVu(frm); frmChiTietChucVu.SetInput("Chuc Vu 1", "20", "Unit Test ma chuc vu", 1); frmChiTietChucVu.TestSave(); List <DMChucVuInfor> list = DMChucVuDataProvider.Search(new DMChucVuInfor { MaChucVu = "20" }); Assert.AreEqual(list.Count, 1); }