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

Add TiddlyWiki integration tests #7

Open
benwebber opened this issue Feb 16, 2019 · 1 comment
Open

Add TiddlyWiki integration tests #7

benwebber opened this issue Feb 16, 2019 · 1 comment

Comments

@benwebber
Copy link
Owner

The dnd module unit tests are alright, but they're a little cumbersome and don't test the actual macro interface.

It'd be better to test the actual wikitext, using TiddlyWiki itself to render the macro. We'd need to instantiate TiddlyWiki in the test suite, then call Wiki.renderTiddler():

https://github.com/Jermolene/TiddlyWiki5/blob/810033bd71abfad14c7d92f340ce26c33eab4ce8/editions/test/tiddlers/tests/test-wikitext.js

@benwebber
Copy link
Owner Author

In order to measure integration test coverage, it may be necessary to run Jest inside TiddlyWiki instead, similar to how the upstream test harness runs Jasmine. That way Jest can instrument virtual modules within the TiddlyWiki module system (e.g., $:/plugins/benwebber/dnd/modules/macros/dnd.xp.js).

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

No branches or pull requests

1 participant