Skip to content

Commit

Permalink
Merge pull request openfoodfoundation#12830 from filipefurtad0/remove…
Browse files Browse the repository at this point in the history
…_pdf_file_test_from_reports

Removes test on PDF file on sales tax report
  • Loading branch information
dacook authored Sep 2, 2024
2 parents af3aed8 + 72a503c commit f9a7634
Showing 1 changed file with 0 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,6 @@

it_behaves_like "reports generated as", "CSV", "csv", false
it_behaves_like "reports generated as", "Spreadsheet", "xlsx", true
it_behaves_like "reports generated as", "PDF", "pdf", true
end
end

Expand All @@ -482,10 +481,6 @@ def load_file_txt(extension, downloaded_filename)
when "xlsx"
xlsx = Roo::Excelx.new(downloaded_filename)
xlsx.map(&:to_a).join(" ")
when "pdf"
# Load PDF pages and contents join into one big string
pdf = PDF::Reader.new(downloaded_filename)
pdf.pages.map(&:text).join(" ")
end
end
end

0 comments on commit f9a7634

Please sign in to comment.