245 lines
14 KiB
Diff
245 lines
14 KiB
Diff
--- a/src/img2pdf_test.py
|
|
+++ b/src/img2pdf_test.py
|
|
@@ -863,7 +863,7 @@ def jpg_img(tmp_path_factory, tmp_normal
|
|
assert "resolution" not in identify[0]["image"]
|
|
assert identify[0]["image"].get("units") == "Undefined", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") == "Undefined", str(identify)
|
|
+ assert identify[0]["image"].get("endianness") == "Undefined", str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
assert identify[0]["image"].get("pageGeometry") == {
|
|
@@ -2219,7 +2219,7 @@ def tiff_float_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -2275,7 +2275,7 @@ def tiff_cmyk8_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "CMYK", str(identify)
|
|
assert identify[0]["image"].get("type") == "ColorSeparation", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -2335,7 +2335,7 @@ def tiff_cmyk16_img(tmp_path_factory, tm
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "CMYK", str(identify)
|
|
assert identify[0]["image"].get("type") == "ColorSeparation", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 16, str(identify)
|
|
@@ -2385,7 +2385,7 @@ def tiff_rgb8_img(tmp_path_factory, tmp_
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -2436,7 +2436,7 @@ def tiff_rgb12_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 12, str(identify)
|
|
@@ -2487,7 +2487,7 @@ def tiff_rgb14_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 14, str(identify)
|
|
@@ -2538,7 +2538,7 @@ def tiff_rgb16_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 16, str(identify)
|
|
@@ -2589,7 +2589,7 @@ def tiff_rgba8_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColorAlpha", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -2640,7 +2640,7 @@ def tiff_rgba16_img(tmp_path_factory, tm
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColorAlpha", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 16, str(identify)
|
|
@@ -2689,7 +2689,7 @@ def tiff_gray1_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Bilevel", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 1, str(identify)
|
|
@@ -2739,7 +2739,7 @@ def tiff_gray2_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Grayscale", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 2, str(identify)
|
|
@@ -2789,7 +2789,7 @@ def tiff_gray4_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Grayscale", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 4, str(identify)
|
|
@@ -2839,7 +2839,7 @@ def tiff_gray8_img(tmp_path_factory, tmp
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Grayscale", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -2889,7 +2889,7 @@ def tiff_gray16_img(tmp_path_factory, tm
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Grayscale", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 16, str(identify)
|
|
@@ -2943,7 +2943,7 @@ def tiff_multipage_img(tmp_path_factory,
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -2986,7 +2986,7 @@ def tiff_multipage_img(tmp_path_factory,
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "TrueColor", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -3036,7 +3036,7 @@ def tiff_palette1_img(tmp_path_factory,
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "Palette", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -3087,7 +3087,7 @@ def tiff_palette2_img(tmp_path_factory,
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "Palette", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -3138,7 +3138,7 @@ def tiff_palette4_img(tmp_path_factory,
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "Palette", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -3189,7 +3189,7 @@ def tiff_palette8_img(tmp_path_factory,
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "sRGB", str(identify)
|
|
assert identify[0]["image"].get("type") == "Palette", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 8, str(identify)
|
|
@@ -3253,7 +3253,7 @@ def tiff_ccitt_lsb_m2l_white_img(tmp_pat
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Bilevel", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 1, str(identify)
|
|
@@ -3334,7 +3334,7 @@ def tiff_ccitt_msb_m2l_white_img(tmp_pat
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Bilevel", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in [
|
|
+ assert identify[0]["image"].get("endianness") in [
|
|
"Undefined",
|
|
"MSB",
|
|
] # FIXME: should be MSB
|
|
@@ -3416,7 +3416,7 @@ def tiff_ccitt_msb_l2m_white_img(tmp_pat
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Bilevel", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in [
|
|
+ assert identify[0]["image"].get("endianness") in [
|
|
"Undefined",
|
|
"MSB",
|
|
] # FIXME: should be MSB
|
|
@@ -3503,7 +3503,7 @@ def tiff_ccitt_lsb_m2l_black_img(tmp_pat
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Bilevel", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 1, str(identify)
|
|
@@ -3593,7 +3593,7 @@ def tiff_ccitt_nometa1_img(tmp_path_fact
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|
|
assert identify[0]["image"].get("type") == "Bilevel", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("depth") == 1, str(identify)
|
|
@@ -3677,7 +3677,7 @@ def tiff_ccitt_nometa2_img(tmp_path_fact
|
|
}, str(identify)
|
|
assert identify[0]["image"].get("units") == "PixelsPerInch", str(identify)
|
|
assert identify[0]["image"].get("type") == "Bilevel", str(identify)
|
|
- assert identify[0]["image"].get("endianess") in ["Undefined", "LSB",], str(
|
|
+ assert identify[0]["image"].get("endianness") in ["Undefined", "LSB",], str(
|
|
identify
|
|
) # FIXME: should be LSB
|
|
assert identify[0]["image"].get("colorspace") == "Gray", str(identify)
|