What is included with this book?
Cédric Beust, a senior software engineer at Google, is an active member of the Java Community Process who has been extensively involved in the development of the latest Java release. He is the creator and main contributor to the TestNG project.
Hani Suleiman is CTO of Formicary, a consulting and portal company specializing in financial applications. He is one of two individual members who has been elected to the Executive Committee of the Java Community Process.
Foreword | p. xiii |
Preface | p. xv |
Acknowledgments | p. xxi |
About the Authors | p. xxiii |
Getting Started | p. 1 |
Beyond JUnit 3 | p. 3 |
JUnit 4 | p. 7 |
Designing for Testability | p. 8 |
TestNG | p. 17 |
Conclusion | p. 21 |
Testing Design Patterns | p. 23 |
Testing for Failures | p. 23 |
Factories | p. 34 |
Data-Driven Testing | p. 39 |
Asynchronous Testing | p. 67 |
Testing Multithreaded Code | p. 71 |
Performance Testing | p. 83 |
Mocks and Stubs | p. 90 |
Dependent Testing | p. 103 |
Inheritance and Annotation Scopes | p. 113 |
Test Groups | p. 119 |
Code Coverage | p. 132 |
Conclusion | p. 150 |
Enterprise Testing | p. 153 |
A Typical Enterprise Scenario | p. 154 |
A Concrete Example | p. 157 |
Test Implementation | p. 160 |
Exploring the Competing Consumers Pattern | p. 182 |
The Role of Refactoring | p. 186 |
Conclusion | p. 194 |
Java EE Testing | p. 197 |
In-Container versus Out-of-Container Testing | p. 198 |
In-Container Testing | p. 200 |
Java Naming and Directory Interface (JNDI) | p. 207 |
Java Database Connectivity (JDBC) | p. 210 |
Java Transaction API (JTA) | p. 215 |
Java Messaging Service (JMS) | p. 219 |
Java Persistence API (JPA) | p. 225 |
Enterprise Java Beans 3.0 (EJB3) | p. 236 |
Java API for XML Web Services (JAX-WS) | p. 246 |
Servlets | p. 255 |
XML | p. 262 |
Conclusion | p. 266 |
Integration | p. 269 |
Guice | p. 280 |
DbUnit | p. 295 |
HtmlUnit | p. 303 |
Selenium | p. 310 |
Swing UI Testing | p. 312 |
Tests for Painting Code | p. 316 |
Continuous Integration | p. 320 |
Conclusion | p. 322 |
Extending TestNG | p. 325 |
The TestNG API | p. 325 |
BeanShell | p. 335 |
Method Selectors | p. 341 |
Annotation Transformers | p. 346 |
Reports | p. 355 |
Writing Custom Annotations | p. 366 |
Conclusion | p. 375 |
Digressions | p. 377 |
Motivation | p. 377 |
The TestNG Philosophy | p. 378 |
The Care and Feeding of Exceptionsv | p. 378 |
Stateful Tests | p. 382 |
The Pitfalls of Test-Driven Development | p. 385 |
Testing Private Methods | p. 388 |
Testing versus Encapsulation | p. 391 |
The Power of Debuggers | p. 392 |
Logging Best Practices | p. 394v |
The Value of Time | p. 397 |
Conclusion | p. 399 |
IDE Integration | p. 401 |
Eclipse | p. 401 |
IntelliJ IDEA | p. 411 |
TestNG Javadocs | p. 421 |
JDK 1.4 and JDK 5 | p. 421 |
Shortcut Syntax for JDK | p. 5 |
Annotations | p. 423 |
Annotation Javadocs | p. 423 |
The org | |
Testng | |
TestNG Class | p. 428 |
The XML API | p. 432 |
testng.xml | p. 435 |
Overview | p. 436 |
Scopes | p. 437 |
XML Tags | p. 437 |
Migrating from JUnit | p. 449 |
JUnitConverter | p. 449 |
Integrated Development Environments | p. 453 |
Incremental Migration and JUnit Mode | p. 455 |
Converting JUnit Code | p. 456 |
Index | p. 471 |
Table of Contents provided by Publisher. All Rights Reserved. |
The New copy of this book will include any supplemental materials advertised. Please check the title of the book to determine if it should include any access cards, study guides, lab manuals, CDs, etc.
The Used, Rental and eBook copies of this book are not guaranteed to include any supplemental materials. Typically, only the book itself is included. This is true even if the title states it includes any access cards, study guides, lab manuals, CDs, etc.