Go
19.5K subscribers
14 photos
143 links
// admin @denniselite
go func() { channel <- news }()
news := <-channel
fmt.Sprintf("%s", news)
Download Telegram
Unit testing and TDD: 5 of simple tips and tricks for improving your tests

1. Put your tests in a different package
2. Internal tests go in a different file
3. Run all tests on save
4. Write table driven tests
5. Mock things using Go code

https://medium.com/@matryer/5-simple-tips-and-tricks-for-writing-unit-tests-in-golang-619653f90742?source=linkShare-b636419a57de-1516079991
GoLang 1.10 Release notes has been added!

Go 1.10 is not yet released. These are work-in-progress release notes. Go 1.10 is expected to be released in February 2018.

This release:
- caching of built packages;
- adds caching of successful test results;
- runs vet automatically during tests;
- permits passing string values directly between Go and C using cgo.

#golang #news #releases
See more:
https://tip.golang.org/doc/go1.10