Book Image

Mastering AngularJS Directives

By : Josh Kurz
Book Image

Mastering AngularJS Directives

By: Josh Kurz

Overview of this book

<p>AngularJS offers many features that allow the creation of rich, compelling web applications. Directives are by far the most important feature to incorporate into any skill set. This book starts off by teaching basic and advanced techniques for the art of directive writing. The different techniques are taught by a series of examples that showcase when and why certain directives should be created, based on given use cases. It moves on to explain more about how to harness the potential of AngularJS, by incorporating external libraries, optimizing code, and using brand new functions such as animations.<br /><br />Finally, the book includes an overview of the techniques and best practices that AngularJS developers need to keep in mind while developing their own applications. The overall goal of this book is to teach different aspects of directive writing that can be consumed by all levels.</p>
Table of Contents (16 chapters)
Mastering AngularJS Directives
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Free Chapter
1
The Tools of the Trade
Index

Testing integrated directives


The act of communication infers that multiple parties are going to be working in unison with each other. This fact suggests that the unit testing processes that have been taken so far in this book will not suffice. When testing multiple directives together, it is common to use integration testing.

Note

Integration tests can be provided by the tools used in all of the tests previously written in this book.

Integration tests

The use of multiple modules together to prove specific use cases is considered an integration test. Testing multiple directives working in collaboration with each other is expected when proving communication between directives is working properly. To accomplish this, multiple directives need to be integrated and compiled together. The integration in this book is referring to the creation of an element that has multiple directives appended to each other inside of a containing element. This type of integration is how all of the integration tests...