4

As like we pass the browser name and other details from command prompt in codecetion, can we pass any variable which can be used within the script from command prompt?

2
  • Could you be more specific? Commented Mar 25, 2015 at 8:17
  • agreed with @Alexander : please revisit the question and elaborate further on it, with specific examples and use cases. Commented Mar 30, 2015 at 13:17

2 Answers 2

2

I didn't find any way to do it in documentation and other feeds.

I add pull request for this ability use params from console in tests

When it will be merged in master you can run tests like this:

php codecept run -p "site-id: 123456, group: admin" -p "duty: free"

You can find more information in PR.

Sign up to request clarification or add additional context in comments.

Comments

0

You can get command prompt parameters here: $_SERVER['argv'];

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.