-
Notifications
You must be signed in to change notification settings - Fork 281
/
image_obj_test.go
71 lines (56 loc) · 1.26 KB
/
image_obj_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
package gopdf
import (
"testing"
)
func TestImagePares(t *testing.T) {
var err error
_, err = parseImgByPath("test/res/gopher01.jpg")
if err != nil {
t.Error(err)
//return
}
_, err = parseImgByPath("test/res/gopher01_g_mode.jpg")
if err != nil {
t.Error(err)
//return
}
_, err = parseImgByPath("test/res/gopher01_i_mode.jpg")
if err != nil {
t.Error(err)
//return
}
//Channel_digital_image_CMYK_color.jpg
_, err = parseImgByPath("test/res/Channel_digital_image_CMYK_color.jpg")
if err != nil {
t.Error(err)
//return
}
_, err = parseImgByPath("test/res/gopher02.png")
if err != nil {
t.Error(err)
return
}
_, err = parseImgByPath("test/res/gopher02.png")
if err != nil {
t.Error(err)
return
}
}
func TestImage02Pares(t *testing.T) {
var err error
//_, err = parseImgByPath("test/res/OpenOffice.org_1.1_official_main_logo_2col_trans.png")
_, err = parseImgByPath("./test/res/PNG_transparency_demonstration_1.png")
if err != nil {
t.Error(err)
//return
}
}
func TestImage03Pares(t *testing.T) {
var err error
_, err = parseImgByPath("test/res/OpenOffice.org_1.1_official_main_logo_2col_trans.png")
//_, err = parseImgByPath("./test/res/PNG_transparency_demonstration_1.png")
if err != nil {
t.Error(err)
//return
}
}