🎉 Go Testing Frameworks Examples v1.0.0
A comprehensive collection of 11 Go testing framework examples with production-ready code and extensive documentation.
✨ Features
- 11 Testing Frameworks - Complete examples for all major Go testing frameworks
- 9/9 Tests Passing - All testable frameworks have working examples
- 100% Documentation - Every framework includes detailed README with examples
- CI/CD Pipeline - GitHub Actions workflow with matrix testing
- Interactive Comparison - Table with live links to each framework
- Production Ready - Well-commented code following best practices
📦 Frameworks Included
Unit Testing
- Built-in Testing - Native Go testing with table-driven tests
- Testify - Assertions and mocking (100% coverage)
BDD Testing
- Ginkgo + Gomega - BDD-style testing (100% coverage)
- GoConvey - BDD with Web UI support
- Godog - Cucumber-style BDD with Gherkin
- Gauge - Acceptance testing with Markdown specs
Mocking
- GoMock - Interface mocking (97.8% coverage)
Advanced Testing
- Gopter - Property-based testing (600+ tests)
- Rapid - Model-based stateful testing (800+ tests)
- Testcontainers - Docker integration testing
- httpexpect - HTTP/REST API testing
🚀 Quick Start
# Clone the repository
git clone https://github.com/lirany1/go-testing-framework-examples.git
cd go-testing-framework-examples
# Download dependencies
go mod tidy
# Run all tests
go test ./01_builtin_testing/... ./02_testify/... ./03_ginkgo_gomega/... \
./04_goconvey/... ./05_gomock/... ./06_godog/... \
./08_gopter/... ./09_rapid/... ./11_httpexpect/...📊 Test Results
All frameworks tested and passing:
- ✅ Built-in Testing
- ✅ Testify
- ✅ Ginkgo + Gomega
- ✅ GoConvey
- ✅ GoMock
- ✅ Godog
- ✅ Gopter
- ✅ Rapid
- ✅ httpexpect
Special requirements:
⚠️ Gauge requires Gauge CLI⚠️ Testcontainers requires Docker
📚 Documentation
Each framework includes:
- Installation instructions
- Feature overview
- Pros and cons
- Usage examples
- Best practices
🏷️ Topics
go golang testing bdd tdd unit-testing integration-testing mocking testify ginkgo goconvey gomock godog gopter testcontainers httpexpect testing-frameworks go-testing best-practices tutorial
🙏 Support
If you find this helpful:
- ⭐ Star this repository
- 🐛 Report issues
- 💡 Suggest improvements
- ☕ Buy me a coffee
Full Changelog: https://github.com/lirany1/go-testing-framework-examples/commits/v1.0.0