Kill some TODOs

- Most fmt.Errorf -> errors.New().
- Add some missing tests.