Merge pull request #110 from cryptix/master

added tests from PR #103
This commit is contained in:
Tyler 2014-12-22 10:16:26 -07:00
commit 2eaa4b48b8

View File

@ -97,6 +97,10 @@ func TestEqual(t *testing.T) {
if !Equal(mockT, int64(123), uint64(123)) {
t.Error("Equal should return true")
}
funcA := func() int { return 42 }
if !Equal(mockT, funcA, funcA) {
t.Error("Equal should return true")
}
}
@ -199,6 +203,11 @@ func TestNotEqual(t *testing.T) {
if !NotEqual(mockT, nil, new(AssertionTesterConformingObject)) {
t.Error("NotEqual should return true")
}
funcA := func() int { return 23 }
funcB := func() int { return 42 }
if !NotEqual(mockT, funcA, funcB) {
t.Error("NotEqual should return true")
}
if NotEqual(mockT, "Hello World", "Hello World") {
t.Error("NotEqual should return false")