About this book
Experienced developers know that designing a comprehensive testing strategy is vital to shipping and maintaining services in production. This book teaches you to leverage TDD, which is already an industry practice, for testing your Go applications at different levels. In addition, one chapter discusses the challenges and approaches of testing concurrent code, which requires different techniques for testing and profiling.
You’ll use TDD to solve and test a variety of problems, from simple mathematical functions to web applications. You’ll learn how to structure and run your unit tests, and what assertion frameworks are available for you to use. You’ll implement test suites using table-driven testing, which is a common technique used in Go. Then, you’ll write and run Behavior-Driven Development (BDD) style tests. You’ll learn more complex topics that require end-to-end testing with mocking and contract testing via practical examples. Finally, you’ll explore the difficult aspects of implementing and running TDD in production. You’ll come across the challenges of testing concurrent code and fuzzing.
By the end of this book, you’ll design and implement a comprehensive testing strategy for your Go applications and microservice architectures.
- Publication date:
- June 2023