In this session from NativeScript Developer Day 2016 in Boston, Nathanael Anderson
discusses how you can take your really cool app; and make sure it continues to work after you make bug fixes and enhancements. The first part of this talk goes through the basics of how to setup and use the built in unit testing in NativeScript to test not only your app but any other additional code including the compiled in plugins. Once you have your unit tests; you will see how easily it is to make sure your code doesn’t break on all your future changes. Unit testing allows you to verify the individual pieces are working.
The second part of the talk deals with how to do end to end testing of your app; this type of testing acts like a end user and will actually click, type, swipe as if a user is doing these things. At the end of each action you can verify the application state is correct. This allows you to verify the whole app is working properly.
Here is a transcript of the questions asked at the end of the presentation:
1. What about testing Angular2 NativeScript apps?
2. What about Code Coverage?
Slide Deck: http://fluentreports.com/blog/wp-content/uploads/2016/09/NativeScript-Testing.pdf
Demo "Carder" App used w/ Tests: https://github.com/NathanaelA/carder
Blog posts about this:
http://fluentreports.com/blog/?p=391 - Part 1 - Unit Testing
http://fluentreports.com/blog/?p=396 - Part 2 - End to End Testing