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

Test documentation examples in browsers #81

Open
robotlolita opened this issue Mar 11, 2017 · 0 comments
Open

Test documentation examples in browsers #81

robotlolita opened this issue Mar 11, 2017 · 0 comments

Comments

@robotlolita
Copy link
Member

robotlolita commented Mar 11, 2017

Currently documentation examples are only tested in Node. This is good enough to make sure that documentation examples are kept in sync with the code, which is very important, but there might be some browser quirks that aren't being caught in these examples, so an user might try them and get frustrated because things won't work. That's not nice.

Since the documentation files are loaded dynamically right now, we can't really package them with Browserify, thus it's necessary to add a new build step that figures out which documentation files have to be loaded and generates a static JavaScript file containing require calls to those. At that point, test/specs-src/documentation.js would just point to the generated file, rather than loading documentation tests dynamically. The browser-tests.js file can them just load that spec like any other.

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

No branches or pull requests

1 participant