コード例 #1
0
ファイル: Tests.cs プロジェクト: GerodruS/DIPS
        public void Test_DeliveryServiceWrongTime()
        {
            ShoppingCart sc = new ShoppingCart();

            Good[] itemIDAndCount = new Good[3];
            for (int i = 0, count = itemIDAndCount.Length; i < count; ++i)
            {
                itemIDAndCount[i].ItemID = i + 1;
                itemIDAndCount[i].Count = 10;
            }

            string dateString = "5/1/2008 5:30:52 AM";
            DateTime time = DateTime.Parse(dateString, System.Globalization.CultureInfo.InvariantCulture);

            sc.createRequest(itemIDAndCount, time, 5);
        }
コード例 #2
0
ファイル: Tests.cs プロジェクト: GerodruS/DIPS
        public void Test_DeliverySystemConfirmFail()
        {
            ShoppingCart sc = new ShoppingCart();

            Good[] itemIDAndCount = new Good[1];
            for (int i = 0, count = itemIDAndCount.Length; i < count; ++i)
            {
                itemIDAndCount[i].ItemID = i + 1;
                itemIDAndCount[i].Count = 5;
            }

            string dateString = "5/1/2008 5:01:52 PM";
            DateTime time = DateTime.Parse(dateString, System.Globalization.CultureInfo.InvariantCulture);

            sc.createRequest(itemIDAndCount, time, 7);
        }
コード例 #3
0
ファイル: Tests.cs プロジェクト: GerodruS/DIPS
        public void Test_SupplierSystemGoodNotFound()
        {
            ShoppingCart sc = new ShoppingCart();

            Good[] itemIDAndCount = new Good[3];
            for (int i = 0, count = itemIDAndCount.Length; i < count; ++i)
            {
                itemIDAndCount[i].ItemID = 10;
                itemIDAndCount[i].Count = 5;
            }

            string dateString = "5/1/2008 5:30:52 PM";
            DateTime time = DateTime.Parse(dateString, System.Globalization.CultureInfo.InvariantCulture);

            sc.createRequest(itemIDAndCount, time, 2);
        }