generator-webapp
generator-webapp copied to clipboard
Feature: Test refactor (No merge)
Please, DO NOT merge it!
This is a working in progress feature. See #759
@silvenon... Let me share with you my approach for this feature.
- My idea was to add an extra function in
app/scripts/main.js
that exports a simple'\'Allo \'Allo!'
text that is used already in the generator. The idea is to test this text in the several frameworks. - I didn't use sub-generators as for most of the frameworks I wasn't able to find one, like Ava. As well I want to add a real test, so the users can really understand how to create tests.
- The code right now is very raw, I will do a refactor once I have all the pieces together.
- Jest and Cypress are working as expected.
- Mocha and Jasmine are quite problematics as I my approach was to use es6 modules, as I did for Cypress or Jest. But I am facing several Babel related issues. I was thinking to add a commonjs version for support mocha and Jamine, until we figure out how to solve the compatilibity with babel.
- As well I added all the test for cover this feature, note that the skipped ones are related to mocha and Jasmine (not implemented yet)
What do you think?