(t *testing.T)
| 110 | } |
| 111 | |
| 112 | func TestImageExtract(t *testing.T) { |
| 113 | buf, err := initImage("test.jpg").Extract(100, 100, 300, 200) |
| 114 | if err != nil { |
| 115 | t.Errorf("Cannot process the image: %s", err) |
| 116 | } |
| 117 | |
| 118 | err = assertSize(buf, 300, 200) |
| 119 | if err != nil { |
| 120 | t.Error(err) |
| 121 | } |
| 122 | |
| 123 | Write("testdata/test_extract_out.jpg", buf) |
| 124 | } |
| 125 | |
| 126 | func TestImageExtractZero(t *testing.T) { |
| 127 | buf, err := initImage("test.jpg").Extract(0, 0, 300, 200) |
nothing calls this directly
no test coverage detected