Open dtopuzov opened 7 years ago
One idea to implement this - allow navigation from unit test to actual page from the application. This way the page will be loaded and you'll be able to run unit tests for its code behind. In case you need e2e ui tests, you can check this article
From @PeterStaev on April 23, 2016 9:57
From what I see currently it is not possible to test UI widgets. I tried to parse a widget with
builder.parse
or just create a new object inside the test and set up properties/bindings but both approaches do not initialize the widget fully (i.e. on android the_createUI
function is not called, on iOSonLoaded
event is never fired). Would be great if we can add tests for UI widgets (especially for people developing UI plugins :))Copied from original issue: NativeScript/nativescript-unit-test-runner#9