code: func compare(name string, data interface{}, actualData []byte) error {
  	expectedDataTmpl, err := ioutil.ReadFile(goldenFileName(name))
  
  	if err != nil {
  		if os.IsNotExist(err) {
  			return newErrFixtureNotFound()
  		}
  
  		return fmt.Errorf("Expected %s to be nil", err.Error())
  	}
  
  	tmpl, err := template.New("test").Parse(string(expectedDataTmpl))
  	if err != nil {
  		return fmt.Errorf("Expected %s to be nil", err.Error())
  	}
  
  	var expectedData bytes.Buffer
  	err = tmpl.Execute(&expectedData, data)
  	if err != nil {
  		return fmt.Errorf("Expected %s to be nil", err.Error())
  	}
  
  	if !bytes.Equal(actualData, expectedData.Bytes()) {
  		return newErrFixtureMismatch(
  			fmt.Sprintf("Result did not match the golden fixture.\n"+
  				"Expected: %s\n"+
  				"Got: %s",
  				string(expectedData.Bytes()),
  				string(actualData)))
  	}
  
  	return nil
  }
docs: // compare is reading the golden fixture file and compare the stored data with
  // the actual data.