ng2-ckeditor
ng2-ckeditor copied to clipboard
Unit Testing with Module
I'm using the current latest Angular CLI (1.0.0-beta.24), and trying to test any code that has ng2-ckeditor in it is proving challenging. Angular 2 switched to webpack, and that's making things interesting. I've included the generic typing for ckeditor as declare var ckeditor: any;, and I've added a reference to ckeditor via the test bootstrap file. However since ckeditor looks for /config.js as well as the theme, it blows up in some instances.
Any test that may interact with the ckeditor instance throws the dreaded 'cannot set property 'dir' of undefined' since I cannot set the config. Any solutions for writing unit tests for components that include this module would be helpful.
I don't know if its possible, this repo is just a wrapper for CKEditor (which have it's own unit tests chain : http://docs.ckeditor.com/#!/guide/dev_tests)
If someone have a solution, i'll take it !