update test code

 * update test code
 * update README with GoDoc