Quick introduction to Ginkgo and Gomega
You'll learn about behavior-driven development (BDD) and two Go libraries - Ginkgo and Gomega, in this lesson.
We'll cover the following...
Ginkgo and Gomega provide a robust and easy-to-use framework for practicing BDD in Go.
What is BDD?
BDD stands for behavior-driven development. The basic idea is to define your system’s behavior at a higher level of abstraction. Often, less technical stakeholders can participate and validate these specifications, which increases the likelihood that the developers actually build a system that meets the requirements. The key point is to connect the behavioral specifications to actual tests. Ginkgo is a BDD framework for Go that can help writing behavior-driven tests.
Quick introduction to Ginkgo
Ginkgo is a framework that builds on top of the standard Go testing package and tooling. You define your BDD tests, but under the cover, Ginkgo creates standard Go tests.
This is powerful for several reasons. It’s easy to migrate to Ginkgo tests because they can co-exist side by side with normal Go tests. You can also take advantage of many other ...