Remove public domain congress.jpg and replace with baiona_color.jpg

For reuse compliance we are phasing out public domain licenses
This commit is contained in:
James R. Barlow 2023-10-18 23:27:33 -07:00
parent cd61c4efd9
commit 9ffb45f283
No known key found for this signature in database
GPG Key ID: E54A300D567E1260
7 changed files with 5 additions and 11 deletions

View File

@ -52,7 +52,6 @@ Copyright: (C) 2012 SmokeyJoe
License: GFDL-1.2-or-later or CC-BY-SA-3.0
Files: tests/resources/c02-22.pdf
tests/resources/congress.jpg
tests/resources/multipage.pdf
Copyright: Public domain
License: public-domain

View File

@ -19,9 +19,6 @@ the copyright holder(s) and license(s) applicable to these resources.
* - c02-22.pdf
- `Project Gutenberg`_, Adventures of Huckleberry Finn, page 22
- difficult OCR image (obscure fonts and illustrations)
* - congress.jpg
- `US Congressional Records`_
- difficult OCR image (color background)
* - graph.pdf
- `Wikimedia:Simple_line_graph_of_ACE_2012_results_by_candidate_sj01.png`_
- image with slanted text
@ -125,8 +122,6 @@ These test resources are assemblies or derivatives from other previously mention
.. _`Project Gutenberg`: https://www.gutenberg.org/files/76/76-h/76-h.htm#c2
.. _`US Congressional Records`: http://www.baxleystamps.com/litho/meiji/courts_1871.jpg
.. _`Wikimedia: Simple_line_graph_of_ACE_2012_results_by_candidate_sj01.png`: https://en.wikipedia.org/wiki/File:Simple_line_graph_of_ACE_2012_results_by_candidate_sj01.png
.. _`Wikimedia: JPEG2000 Lichtenstein`: https://en.wikipedia.org/wiki/JPEG_2000#/media/File:Jpeg2000_2-level_wavelet_transform-lichtenstein.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 128 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 101 KiB

View File

@ -75,7 +75,7 @@ def test_img2pdf_fails(resources, no_outpdf):
@pytest.mark.xfail(reason="remove background disabled")
def test_jpeg_in_jpeg_out(resources, outpdf):
check_ocrmypdf(
resources / 'congress.jpg',
resources / 'baiona_color.jpg',
outpdf,
'--image-dpi',
'100',

View File

@ -623,7 +623,7 @@ def test_no_contents(resources, outpdf):
@pytest.mark.parametrize(
'image', ['baiona.png', 'baiona_gray.png', 'baiona_alpha.png', 'congress.jpg']
'image', ['baiona.png', 'baiona_gray.png', 'baiona_alpha.png', 'baiona_color.jpg']
)
def test_compression_preserved(ocrmypdf_exec, resources, image, outpdf):
input_file = str(resources / image)
@ -679,7 +679,7 @@ def test_compression_preserved(ocrmypdf_exec, resources, image, outpdf):
[
('baiona.png', 'jpeg'),
('baiona_gray.png', 'lossless'),
('congress.jpg', 'lossless'),
('baiona_color.jpg', 'lossless'),
],
)
def test_compression_changed(ocrmypdf_exec, resources, image, compression, outpdf):

View File

@ -46,11 +46,11 @@ def test_deskew_blank_page(resources, outpdf):
@pytest.mark.xfail(reason="remove background disabled")
def test_remove_background(resources, outdir):
# Ensure the input image does not contain pure white/black
with Image.open(resources / 'congress.jpg') as im:
with Image.open(resources / 'baiona_color.jpg') as im:
assert im.getextrema() != ((0, 255), (0, 255), (0, 255))
output_pdf = check_ocrmypdf(
resources / 'congress.jpg',
resources / 'baiona_color.jpg',
outdir / 'test_remove_bg.pdf',
'--remove-background',
'--image-dpi',