Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.
 
 
 

19 wiersze
427 B

  1. package altsrc
  2. import (
  3. "reflect"
  4. "testing"
  5. )
  6. func expect(t *testing.T, a interface{}, b interface{}) {
  7. if !reflect.DeepEqual(b, a) {
  8. t.Errorf("Expected %#v (type %v) - Got %#v (type %v)", b, reflect.TypeOf(b), a, reflect.TypeOf(a))
  9. }
  10. }
  11. func refute(t *testing.T, a interface{}, b interface{}) {
  12. if a == b {
  13. t.Errorf("Did not expect %v (type %v) - Got %v (type %v)", b, reflect.TypeOf(b), a, reflect.TypeOf(a))
  14. }
  15. }