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

[WIP][PoC] add behat to github actions #71

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

oallain
Copy link
Member

@oallain oallain commented Jul 26, 2020

Q A
Branch? master
Bug fix? yes
New feature? yes
BC breaks? yes
Deprecations? yes
Related tickets partially #60
License MIT

working-directory: ./sylius
run: |
echo "const bootstrapTheme = require('./themes/BootstrapTheme/webpack.config');" >> webpack.config.js
echo "module.exports = [bootstrapTheme];" >> webpack.config.js
Copy link
Contributor

Choose a reason for hiding this comment

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

Does this not leave us with 2 "module.exports = .." lines in the webpack.config.js file? I think this would override the previous assignment containing the shop and admin exports.

- name: Composer - Github Auth
run: composer config -g github-oauth.github.com ${{ github.token }}

- name: Composer - Install Sylius-Standard
Copy link
Contributor

Choose a reason for hiding this comment

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

There are a lot of similarities with what's happening in the Dockerfile of #66 here.

.github/workflows/behat.yaml Outdated Show resolved Hide resolved
@oallain oallain force-pushed the github-actions-behat branch 20 times, most recently from dd487e0 to f090143 Compare November 15, 2020 19:49
@4c0n
Copy link
Contributor

4c0n commented Nov 16, 2020

Please keep in mind that currently when you run behat, you're just running the tests against the standard sylius version, without the theme, as that is controlled in the scenarios themselves. I don't see any code where you're overriding anything to make sure the right theme is selected for the channel that is used in the tests, or are somehow updating the channel that is added by the tests.

Also wouldn't it be good to run the tests in the container setup? That way development and testing can be done in the exact same environment, no matter what system is being used... Preventing the whole "works on my machine" syndrome.

@oallain
Copy link
Member Author

oallain commented Nov 16, 2020

Hello @4c0n

Thanks for feedbacks.

Please keep in mind that currently when you run behat, you're just running the tests against the standard sylius version, without the theme, as that is controlled in the scenarios themselves. I don't see any code where you're overriding anything to make sure the right theme is selected for the channel that is used in the tests, or are somehow updating the channel that is added by the tests.

I forced sylius/bootstrap-theme in step :
https://github.com/Sylius/BootstrapTheme/pull/71/files#diff-cdce82e9a7520e499cfed0c6b68a24a25fe1ed5613d70f6777a2eb95aceabc17R138
Do you have a better solution ?

Also wouldn't it be good to run the tests in the container setup? That way development and testing can be done in the exact same environment, no matter what system is being used... Preventing the whole "works on my machine" syndrome.

We can do that, yes. But I would like to make them work like this already, and then we can use a custom container.
It suits you ?

Regards,

@4c0n
Copy link
Contributor

4c0n commented Nov 16, 2020

@oallain ah I missed that part. Someone came up with this solution: https://gist.github.com/anthid/dcc214804354c8d81013453d83aa219f
I think there is or was also a PR he made for this, but I can't find it right now.

Sure the containers can come later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants