Exemplo n.º 1
0
 /**
  * @group aa
  * @guy OrdersTester\OrdersSteps
  */
 public function VerifyTotalPriceAddInFieldAmount(OrdersTester\OrdersSteps $I)
 {
     $I->wantTo('Check the map editing the amount of added an item to cart and the correct calculation of the amount of order.');
     $I->createProduct($nameProduct = 'Prd0 for1 Цыкл2 подсчета3 и4 отображения5 Edit6', $nameVariantProduct = NULL, $priceProduct = 1);
     $I->click(\NavigationBarPage::$Orders);
     $I->click(\NavigationBarPage::$OrdersList);
     $I->wait('1');
     $I->click(\OrdersListPage::$ListButtCreateOrder);
     $I->wait('1');
     $I->fillField('#productNameForOrders', 'Prd0 for1 Цыкл2 подсчета3 и4 отображения5 Edit6');
     $I->wait('1');
     $I->click('//body/ul[2]/li[1]/a');
     $I->wait('1');
     $I->click(CreateOrderAdminPage::$CrtPButtAddToCart);
     for ($j = 1; $j < 2147483647; $j = $j + 88998899) {
         $I->click(CreateOrderAdminPage::$CrtPButtProduct);
         $I->wait('1');
         $a = $I->grabValueFrom(CreateOrderAdminPage::$CrtPFieldAmount);
         $I->comment("Amount Product In Basket({$a})");
         $I->fillField(CreateOrderAdminPage::$CrtPFieldAmount, "{$j}");
         $I->wait('1');
         $I->see("{$j}", CreateOrderAdminPage::$CrtPFieldTotalPrice);
         $I->see("{$j}", CreateOrderAdminPage::$CrtPFieldCommon);
         $I->click(CreateOrderAdminPage::$CrtPButtOrder);
         $I->click(CreateOrderAdminPage::$CrtOButtUpdate);
         $I->seeInField(CreateOrderAdminPage::$CrtOFieldTotalPrice, "{$j}");
     }
 }
Exemplo n.º 2
0
 /**
  * @group a
  * @guy OrdersTester\OrdersSteps
  */
 public function VerifyFieldAmountInputSymbols(OrdersTester\OrdersSteps $I)
 {
     //Amount 09876543432
     $I->wantTo('Verify input invalid values in field Amount".');
     $I->createProduct($nameProduct = 'Amount 09876543432', $nameVariantProduct = NULL, $priceProduct = 1);
     $I->click(\NavigationBarPage::$Orders);
     $I->click(\NavigationBarPage::$OrdersList);
     $I->wait('3');
     $I->click(\OrdersListPage::$ListButtCreateOrder);
     $I->wait('3');
     $I->fillField('#productNameForOrders', 'Amount 09876543432');
     $I->wait('1');
     $I->click('//body/ul[2]/li[1]/a');
     $I->wait('1');
     $I->click(CreateOrderAdminPage::$CrtPButtAddToCart);
     $I->fillField(CreateOrderAdminPage::$CrtPFieldAmount, ' ');
     $I->dontSeeInField(CreateOrderAdminPage::$CrtPFieldAmount, ' ');
     $I->fillField(CreateOrderAdminPage::$CrtPFieldAmount, InitTest::$textSymbols);
     $I->dontSeeInField(CreateOrderAdminPage::$CrtPFieldAmount, InitTest::$textSymbols);
     $I->seeInField(CreateOrderAdminPage::$CrtPFieldAmount, '1234567890.');
 }
Exemplo n.º 3
0
 /**
  * @group a
  * @guy OrdersTester\OrdersSteps
  */
 public function VerifyFieldDefoultAmountInBasket(OrdersTester\OrdersSteps $I)
 {
     $I->wantTo('VerifyDefoltValueOnFieldAmount.');
     $I->createProduct($nameProduct = 'ТоварVerify Defoult98765 AmountinBasket', $nameVariantProduct = NULL, $priceProduct = 1);
     $I->click(\NavigationBarPage::$Orders);
     $I->click(\NavigationBarPage::$OrdersList);
     $I->wait('2');
     $I->click(\OrdersListPage::$ListButtCreateOrder);
     $I->wait('2');
     $I->fillField('//table[1]/tbody/tr[1]/td[1]/div/input', 'ТоварVerify Defoult98765 AmountinBasket');
     $I->wait('1');
     $I->click('//body/ul[2]/li[1]/a');
     $I->wait('1');
     $I->click(CreateOrderAdminPage::$CrtPButtAddToCart);
     $I->seeInField(CreateOrderAdminPage::$CrtPFieldAmount, '1');
     $I->see('1.00', CreateOrderAdminPage::$CrtPFieldTotalPrice);
     $I->see('1.00', CreateOrderAdminPage::$CrtPFieldCommon);
     $I->click(CreateOrderAdminPage::$CrtPButtOrder);
     $I->click(CreateOrderAdminPage::$CrtOButtUpdate);
     $I->seeInField(CreateOrderAdminPage::$CrtOFieldTotalPrice, '1.00');
 }