Parting thoughts, next steps, and future ideas

We are now at the end of our journey through the fundamentals of testing Backbone.js applications with Mocha, Chai, and Sinon.JS. We have explored the background, configuration, and use of each of these test frameworks and tried out a number of complementary tools and helpers. We have reviewed Backbone.js application development, specific component testing goals, and written test collections around a full Backbone.js application. So, what comes next?

Our first suggestion is to review the online documentation for the various testing technologies. The official APIs and guides for all of the frameworks we use in the book are quite good and can provide starting points for more complicated test scenarios that may arise in real-world Backbone.js application development. As a refresher, the documentation sites for our core test stack include the following:

After the framework documentation, you can review the article, blog, and book suggestions that we have provided throughout this book. In particular, the references in Chapter 2, Creating a Backbone.js Application Test Plan on general test methodology and Backbone.js testing are great resources for those seeking a broader background in the software development and testing techniques appropriate for larger-scale Backbone.js applications.

Finally, we suggest that you download and install the book code samples. These samples are essentially the practical application of the principles we have covered in this book, with useful applications, tests, and files put together in a single package. Additionally, they provide examples of more testing and automation techniques for you to explore on your own, including the following:

  • Style checking: JavaScript style checkers automatically analyze source files to find language or convention errors. Checkers are invaluable during software development, often finding programming errors early on and in places that tests can miss. Additionally, style checkers can enforce consistent coding styles for all members of a team working on a single application. The code samples use JSHint (http://www.jshint.com/) to check all of the application and test examples that we have discussed in this book. You can inspect the package.json file in the code samples to see our JSHint usage in the script commands style, style-server, and style-client.
  • Code coverage: Code coverage is a technique to quantify how much of an application is actually exercised by tests. Coverage tools run behind the scenes during tests, recording which application code lines are executed, and provide a report that measures the lines covered in each application file. The code samples provide a test driver page for the Notes application at notes/test/coverage.html that uses Blanket.js (http://blanketjs.org/) to provide a coverage report. You can run the Notes test and the coverage report online at http://backbone-testing.com/notes/test/coverage.html.

The rest is left up to you. While we are at the end of the road for this book, the world of testing will keep pushing forward in new and interesting ways. We bid you good luck in your continued learning and discovery of more testing tools, methods, and topics for Backbone.js application development.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.119.166.90