Closed

Description
Preconditions
- MFTF 2.1.2
- PHP 7.0.28
Steps to reproduce
- Create a
Page
file/entity for the backend that references a variable in its URL, e.g.<page name="AdminProductEditPage" url="catalog/product/edit/id/{{id}}/" area="admin" module="Magento_Catalog" parameterized="true">
- Inside a test make a reference to that page and pass it an entity that was created during the test. For example have this:
<createData entity="_defaultCategory" stepKey="createCategory"/>
<createData entity="_defaultProduct" stepKey="createSimpleStandaloneProduct">
<requiredEntity createDataKey="createCategory"/>
</createData>
Then have this:
<amOnPage url="{{AdminProductEditPage.url($$createSimpleStandaloneProduct.id$$)}}" stepKey="goToProductEditPage1"/>
- Generate the test that contains those steps.
Expected result
- The step that uses the
amOnPage
action should look like this:
$I->amOnPage("/" . getenv("MAGENTO_BACKEND_NAME") . "/catalog/product/edit/id/" . $this->createSimpleStandaloneProduct->getCreatedDataByName('id') . "/");
Actual result
- The step actually looks like this:
$I->amOnPage("/" . getenv("MAGENTO_BACKEND_NAME") . "/catalog/product/edit/id/$$createSimpleStandaloneProduct.id$$/");
This only happens on admin pages. Will open a pull request to fix this.
Metadata
Metadata
Assignees
Labels
No labels