Book description
Over 35 recipes to design and develop Jasmine tests to produce world-class JavaScript applications
In Detail
Jasmine provides a rich set of libraries to design and develop tests for JavaScript applications. Its tests aim to run on any JavaScript-enabled platform and have easy-to-read syntax.
This book is a comprehensive guide to designing and developing Jasmine tests to produce world-class software. The recipes are elaborated using examples from a real-world application, which involves various aspects of designing and developing tests from simple to complex level. You will learn how to create tests for jQuery and Ajax, HTML and JSON fixtures, CoffeeScript, and AngularJS. By learning and applying the best practices throughout this book, you can deliver your applications with zero defects and ensure success for you and your clients.
What You Will Learn
Develop JavaScript applications with Jasmine using the behavior-driven development (BDD) process
Apply custom matchers by enhancing your Jasmine tests to test specific features or functionality
Design Jasmine specs for jQuery and Ajax with HTML and JSON fixtures
Generate code coverage analysis for JavaScript code using Karma and Istanbul
Create Jasmine tests for CoffeeScript and AngularJS
Implement E2E (end-to-end) Jasmine specs for JavaScript applications to simulate a real-time scenario
Table of contents
-
Jasmine Cookbook
- Table of Contents
- Jasmine Cookbook
- Credits
- About the Author
- About the Reviewer
- www.PacktPub.com
- Preface
- 1. Getting Started with Jasmine Framework
- 2. Jasmine with TDD and BDD Processes
- 3. Customizing Matchers and Jasmine Functions
- 4. Designing Specs from Requirement
-
5. Jasmine Spies
- Introduction
- Writing Jasmine tests using the spyOn() method and special matchers for spies
- Writing Jasmine tests using tracking properties
- Writing Jasmine tests with your own custom spy method
- Using jasmine.any and jasmine.objectContaining
- Writing Jasmine tests to mock the JavaScript timeout functions
- 6. Jasmine with AJAX, jQuery, and Fixtures
- 7. Code Coverage with Jasmine Tests
- 8. Jasmine with Other Tools
- 9. Developing JavaScript Apps Using Jasmine – a Real-time Scenario
- Index
Product information
- Title: Jasmine Cookbook
- Author(s):
- Release date: April 2015
- Publisher(s): Packt Publishing
- ISBN: 9781784397166
You might also like
book
AngularJS: Maintaining Web Applications
Get started with speed building AngularJS applications, and scale up to a full-stack web application, using …
book
Full Stack Development with JHipster
Discover the world of Full Stack Development with real-world examples. About This Book Leverage the full …
book
Professional AngularJS
A comprehensive guide to AngularJS, Google's open-source client-side framework for app development. Most of the existing …
book
Jasmine JavaScript Testing - Second Edition
Test your JavaScript applications efficiently using Jasmine and React.js In Detail Take your testing of JavaScript …