MageTest / BehatMage

Behat for Magento
MIT License
85 stars 31 forks source link

Some practical questions for multi Magento version setup for module development #36

Closed jasperdcbe closed 10 years ago

jasperdcbe commented 10 years ago

I have been working on writing some tests for a shipping module we have developed for a customer.

Now everything works fine, but one thing I was not able to figure out yet is how we should set the system up to test multiple Magento versions.

We could use modman/composer to install all Magento versions and drop in the module. But I think in this case we would still only be able to test 1 version at a time. Because of the PSR-0 autoloading mapping done in the composer.json file.

So my question is: does anyone have experience with setting up testing for multiple Magento versions using Composer? Maybe to even install the entire Magento installation using it? (we would like to use Composer because it's definitely becoming a solid industry standard)

Edit: also, the tests are not included in the source code of the module, although this is done in this implementation: https://github.com/magento-hackathon/MageBehat What are the pro's/con's? Any thoughts on this?

Many thanks in advance!

jamescowie commented 10 years ago

Hello @jasperdcbe

A little late to replying but the way that I have been testing this module is via a vagrant box and chef to provision. Using sites and pulling magento from a git mirror for the different versions.

https://github.com/jamescowie/Magento-Chef

This is my starting point for this project that can install 1.9 from a git mirror, you should be able to amend and add sites to create many more versions. Once I have time I will update that project to have more versions of Magento installed by default.