good tests for the api, and allows to crosscheck against go code