Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

executeInSelenium action does not generate proper code #332

Merged
merged 4 commits into from
Apr 24, 2019

Conversation

zakdma
Copy link
Contributor

@zakdma zakdma commented Apr 15, 2019

executeInSelenium action does not generate proper code because this action was not included in ActionObject::FUNCTION_CLOSURE_ACTIONS

Steps to reproduce

  1. Create test with executeInSelenium action
    <executeInSelenium function="function ($webdriver) { return 'Hello, World!'}" stepKey="testStep"/>
  2. Run vendor/bin/mftf generate:tests

Expected result

There is generated action
$I->executeInSelenium(function ($webdriver) { return 'Hello, World!'});
Function is passed as Closure.

Actual result

There is generated action
$I->executeInSelenium("function ($webdriver) { return 'Hello, World!'}");
Function is passed as string not Closure. So if you run test you will get exception here.

Contribution checklist

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/verification tests (if applicable)
  • All automated tests passed successfully (all builds on Travis CI are green)
  • Changes to Framework doesn't have backward incompatible changes for tests or have related Pull Request with fixes to tests

@magento-cicd2
Copy link

magento-cicd2 commented Apr 15, 2019

CLA assistant check
All committers have signed the CLA.

@coveralls
Copy link

coveralls commented Apr 15, 2019

Coverage Status

Coverage decreased (-1.0%) to 54.658% when pulling 3e63818 on zakdma:executeInSelenium into a86f010 on magento:develop.

@KevinBKozan
Copy link
Contributor

Hey @zakdma, thank you for your contribution! We'll be processing your PR shortly, and I created an internal ticket to track progress.

Copy link
Contributor

@jilu1 jilu1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution!
Code and test look good. Minor comment inlined.

@jilu1 jilu1 merged commit 4317cc7 into magento:develop Apr 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants