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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add scalar types in Behat/Page/Admin directory #10045

Merged
merged 1 commit into from Dec 20, 2018

Conversation

Zales0123
Copy link
Member

@Zales0123 Zales0123 commented Dec 19, 2018

Q A
Branch? 1.2
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Related tickets
License MIT

Million years ago, we introduced scalar types to Sylius code (#8425) and it is a blessing :) However, our (big and strong) Behat-related code is still missing them. I know, they're not so valuable for the test code, but still allows us to reduce amount of unnecessary inaccuracies (and code lines :)). We should do something about it, or we will stay without these PHP7 features until PHP8 馃槃

This PR aims to add scalar types only in admin pages, which means src/Sylius/Behat/Page/Admin directory. Rest of the changes are just required to avoid failing tests. I believe it's doable to introduce scalar types in a reasonable amount of time and energy for the whole Behat suite, but it should be done in separated PR's per section.

To be honest, it was not so bad as I've expected 馃悆

@Zales0123 Zales0123 added the Behat Issues and PRs aimed at improving Behat usage. label Dec 19, 2018
@Zales0123 Zales0123 requested a review from a team as a code owner December 19, 2018 14:54
Copy link
Contributor

@pamil pamil left a comment

Choose a reason for hiding this comment

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

There are still a few places inside admin pages without typehints, but it's definitely an improvement.

@pamil pamil merged commit d7e3b0c into Sylius:1.2 Dec 20, 2018
@pamil
Copy link
Contributor

pamil commented Dec 20, 2018

Thank you, Mateusz! 馃帀

@Zales0123
Copy link
Member Author

I'm totally aware it's not 100% of coverage 馃槃 But yes, I also believe that with all these scalar types introduced, people would be more eager to add them when they're missing, during a regular refactoring ;) Thanks!

@Zales0123 Zales0123 deleted the behat-scalar-types/admin-pages branch December 20, 2018 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Behat Issues and PRs aimed at improving Behat usage.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants