Corrections as a result of writing an integration test.

Also made btcd_test.go use table-driven tests and use constants like ifoc_test.

This closes #9