Fix image_test.go to check if something is rendered

This commit is contained in:
Hajime Hoshi 2014-12-25 18:41:59 +09:00
parent 90665944b9
commit f603859b01

View File

@ -124,6 +124,12 @@ func TestComposition(t *testing.T) {
if 1 < diff(c1.R, c2.R) || 1 < diff(c1.G, c2.G) || 1 < diff(c1.B, c2.B) || 1 < diff(c1.A, c2.A) {
t.Errorf("img_12_3.At(%d, %d) = %#v; img_1_23.At(%[1]d, %[2]d) = %#[4]v", i, j, c1, c2)
}
if c1.A == 0 {
t.Fatalf("img_12_3.At(%d, %d).A = 0; nothing is rendered?", i, j)
}
if c2.A == 0 {
t.Fatalf("img_1_23.At(%d, %d).A = 0; nothing is rendered?", i, j)
}
}
}
}