示例#1
0
        public void TestMethodDefaultPay_1_Not()
        {
            ChargedForm f2 = new ChargedForm();
            double      hPay = 120, workHours = 10;
            double      test = 3000;

            f2.WorkTimeTextBox.Text          = hPay.ToString();
            f2.WorkedTimeTextBox.Text        = workHours.ToString();
            f2.IsHoursPayRadioButton.Checked = true;

            double result = f2.CalcDefaultPay();

            Assert.AreNotEqual(test, result);
        }
示例#2
0
        public void TestMethodDefaultPay_2_Not()
        {
            ChargedForm f2 = new ChargedForm();
            double      dPay = 1200, workDays = 30;
            double      test = 100;

            f2.WorkTimeTextBox.Text         = dPay.ToString();
            f2.WorkedTimeTextBox.Text       = workDays.ToString();
            f2.IsDaysPayRadioButton.Checked = true;

            double result = f2.CalcDefaultPay();

            Assert.AreNotEqual(test, result);
        }
示例#3
0
        public void TestMethodDefaultPay_3_Not()
        {
            ChargedForm f2 = new ChargedForm();
            double      allPay = 2000, allDays = 30, workDays = 15;
            double      test = 2000;

            f2.WorkTimeTextBox.Text        = allDays.ToString();
            f2.WorkedTimeTextBox.Text      = workDays.ToString();
            f2.SalaryTextBox.Text          = allPay.ToString();
            f2.IsSalaryRadioButton.Checked = true;

            double result = f2.CalcDefaultPay();

            Assert.AreNotEqual(test, result);
        }
示例#4
0
        public void TestMethodDefaultPay_Premia_Not()
        {
            ChargedForm f2   = new ChargedForm();
            double      test = 200;

            f2.ExistBonuseCheckBox.Checked   = true;
            f2.BonuseTextBox.Text            = 2000.ToString();
            f2.IsHoursPayRadioButton.Checked = false;
            f2.IsDaysPayRadioButton.Checked  = false;
            f2.IsSalaryRadioButton.Checked   = false;

            double result = f2.CalcDefaultPay();

            Assert.AreNotEqual(test, result);
        }