diff --git a/src/example1/example1_test.go b/src/example1/example1_test.go index 58a66b8..e4e0abd 100644 --- a/src/example1/example1_test.go +++ b/src/example1/example1_test.go @@ -5,7 +5,7 @@ import ( ) func Test1(t *testing.T) { - if 4 != 4 { + if 3 != 4 { t.Error("Expected 2 + 2 to equal 4") } } @@ -15,7 +15,7 @@ func Test2(t *testing.T) { t.Fail() } - //t.Error("Some other string {}" , 42) + t.Error("Some other string {}" , 42) t.Log("foobar, log") } \ No newline at end of file diff --git a/src/example2/example2_test.go b/src/example2/example2_test.go index 61baa9a..6765a74 100644 --- a/src/example2/example2_test.go +++ b/src/example2/example2_test.go @@ -6,7 +6,7 @@ import ( func TestX(t *testing.T) { - if !true { + if true { t.Fatal("Fatal error"); } @@ -15,7 +15,7 @@ func TestX(t *testing.T) { func TestY(t *testing.T) { t.Log("Some logging") - if false { + if !false { t.FailNow() }