/** * Edit Currency Symbol Entity test. * * @param CurrencySymbolEntity $currencySymbol * @return CatalogProductSimple[] */ public function test(CurrencySymbolEntity $currencySymbol) { // Preconditions: $this->applyCurrencyInConfig(); $this->importCurrencyRates(); $product = $this->createSimpleProductWithCategory(); // Steps: $this->currencySymbolIndex->open(); $this->currencySymbolIndex->getCurrencySymbolForm()->fill($currencySymbol); $this->currencySymbolIndex->getPageActions()->save(); return ['product' => $product]; }
/** * Assert that after clicking on 'Save Currency Symbols' button success message appears. * * @param SystemCurrencySymbolIndex $currencySymbolIndex * @return void */ public function processAssert(SystemCurrencySymbolIndex $currencySymbolIndex) { \PHPUnit_Framework_Assert::assertEquals(self::SUCCESS_SAVE_MESSAGE, $currencySymbolIndex->getMessagesBlock()->getSuccessMessages(), 'Wrong success message is displayed.'); }