Sha256: 6dc3ba86a3492a52e6f3352d0b26887ad10f5222cc1e0f9c7d99ea015257d398
Contents?: true
Size: 917 Bytes
Versions: 1
Compression:
Stored size: 917 Bytes
Contents
# -*- encoding : utf-8 -*- require 'spec_helper' describe OCRSDK::PDF do describe ".recognizeable?" do it "should return false for a document with text only" do OCRSDK::PDF.new(TestFiles.lorem_pdf).recognizeable?.should be_false end it "should return false for document with a lot of text and some images" do OCRSDK::PDF.new(TestFiles.lorem_complex_pdf).recognizeable?.should be_false end it "should return true for document with images only" do OCRSDK::PDF.new(TestFiles.recognizeable_pdf).recognizeable?.should be_true end it "should return false for malformed document" do OCRSDK::PDF.new(TestFiles.malformed_pdf).recognizeable?.should be_false end it "should return true for 'searchable' document with malformed text underneath the pic" do OCRSDK::PDF.new(TestFiles.searchable_malformed_pdf).recognizeable?.should be_true end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ocrsdk-0.1.0 | spec/ocrsdk/pdf_spec.rb |