Example #1
0
        public void NegTestGallons()
        {
            double actual27;
            double expected27 = -0.0067999;

            WindowsFormsApplication5.Form1 test = new WindowsFormsApplication5.Form1();
            //test.Show();
            //test.Activate();

            test.textBox20.Text = "-2"; // linear diamter
            test.textBox21.Text = "-3"; // rod diamter
            test.textBox22.Text = "-1"; // linear length
            test.textBox23.Text = "-1"; // volumetric effeciancy

            test.button19_Click(null, null);

            actual27 = Convert.ToDouble(test.textBox27.Text);

            Assert.AreEqual(expected27, actual27);
        }
Example #2
0
        public void NegTestCubicInches()
        {
            double actual26;
            double expected26 = -1.570796;

            WindowsFormsApplication5.Form1 test = new WindowsFormsApplication5.Form1();
            //test.Show();
            //test.Activate();

            test.textBox20.Text = "-2"; // linear diamter
            test.textBox21.Text = "-3"; // rod diamter
            test.textBox22.Text = "-1"; // linear length
            test.textBox23.Text = "-1"; // volumetric effeciancy

            test.button19_Click(null, null);

            actual26 = Convert.ToDouble(test.textBox26.Text);

            Assert.AreEqual(expected26, actual26);
        }
Example #3
0
        public void PosTestBarrels()
        {
            double actual28;
            double expected28 = 0.26984;

            WindowsFormsApplication5.Form1 test = new WindowsFormsApplication5.Form1();
            //test.Show();
            //test.Activate();

            test.textBox20.Text = "12"; // linear diamter
            test.textBox21.Text = "13"; // rod diamter
            test.textBox22.Text = "14"; // linear length
            test.textBox23.Text = "1"; // volumetric effeciancy

            test.button19_Click(null, null);

            actual28 = Convert.ToDouble(test.textBox28.Text);

            Assert.AreEqual(expected28, actual28);
        }
Example #4
0
        public void TriplexZeroTestGallons()
        {
            double actual27;
            double expected27 = 0;

            WindowsFormsApplication5.Form1 test = new WindowsFormsApplication5.Form1();
            //test.Show();
            //test.Activate();

            test.radioButton20.Checked = true;
            test.textBox20.Text = "0"; // linear diamter
            test.textBox22.Text = "0"; // linear length
            test.textBox23.Text = "0"; // volumetric effeciancy

            test.button19_Click(null, null);

            actual27 = Convert.ToDouble(test.textBox27.Text);

            Assert.AreEqual(expected27, actual27);
        }
Example #5
0
        public void TriplexPosTestCubicInches()
        {
            double actual26;
            double expected26 = 4752;

            WindowsFormsApplication5.Form1 test = new WindowsFormsApplication5.Form1();
            //test.Show();
            //test.Activate();

            test.radioButton20.Checked = true;
            test.textBox20.Text = "12"; // linear diamter
            test.textBox22.Text = "14"; // linear length
            test.textBox23.Text = "1"; // volumetric effeciancy

            test.button19_Click(null, null);

            actual26 = Convert.ToDouble(test.textBox26.Text);

            Assert.AreEqual(expected26, actual26, "ROUNDING ERROR");
        }
Example #6
0
        public void TriplexNegTestBarrels()
        {
            double actual28;
            double expected28 = 0.000971817;

            WindowsFormsApplication5.Form1 test = new WindowsFormsApplication5.Form1();
            //test.Show();
            //test.Activate();

            test.radioButton20.Checked = true;
            test.textBox20.Text = "-2"; // linear diamter
            test.textBox22.Text = "-1"; // linear length
            test.textBox23.Text = "-1"; // volumetric effeciancy

            test.button19_Click(null, null);

            actual28 = Convert.ToDouble(test.textBox28.Text);

            Assert.AreEqual(expected28, actual28, "ROUNDING ERROR");
        }
Example #7
0
        public void PosTestGallons()
        {
            double actual27;
            double expected27 = 11.33333;

            WindowsFormsApplication5.Form1 test = new WindowsFormsApplication5.Form1();
            //test.Show();
            //test.Activate();

            test.textBox20.Text = "12"; // linear diamter
            test.textBox21.Text = "13"; // rod diamter
            test.textBox22.Text = "14"; // linear length
            test.textBox23.Text = "1"; // volumetric effeciancy

            test.button19_Click(null, null);

            actual27 = Convert.ToDouble(test.textBox27.Text);

            Assert.AreEqual(expected27, actual27, "SHOULD BE EQUAL");
        }