Exemple #1
0
        public void ReportByCustomerNameNoneFound()
        {
            clsOrderLineCollection FilteredOrderLines = new clsOrderLineCollection();

            FilteredOrderLines.ReportByCustomerName("xxxxxx xxxxxx");
            Assert.AreEqual(0, FilteredOrderLines.Count);
        }
Exemple #2
0
        public void ReportByCustomerNameOK()
        {
            clsOrderLineCollection AllOrderLines      = new clsOrderLineCollection();
            clsOrderLineCollection FilteredOrderLines = new clsOrderLineCollection();

            FilteredOrderLines.ReportByCustomerName("");
            Assert.AreEqual(AllOrderLines.Count, FilteredOrderLines.Count);
        }
Exemple #3
0
        public void ReportByCustomerNameTestDataFound()
        {
            clsOrderLineCollection FilteredOrderLines = new clsOrderLineCollection();
            Boolean OK = true;

            FilteredOrderLines.ReportByCustomerName("Emma Wang");
            if (FilteredOrderLines.Count == 2)
            {
                if (FilteredOrderLines.OrderLineList[0].OrderNo != 1)
                {
                    OK = false;
                }
                if (FilteredOrderLines.OrderLineList[1].OrderNo != 2)
                {
                    OK = false;
                }
            }
            else
            {
                OK = false;
            }
            Assert.IsTrue(OK);
        }