test/hexapdf/test_revision.rb in hexapdf-0.11.9 vs test/hexapdf/test_revision.rb in hexapdf-0.12.0

- old
+ new

@@ -112,22 +112,25 @@ it "deletes objects specified by reference" do @rev.delete(@ref, mark_as_free: false) refute(@rev.object?(@ref)) assert(@obj.null?) + assert_raises(HexaPDF::Error) { @obj.document } end it "deletes objects specified by object number" do @rev.delete(@ref.oid, mark_as_free: false) refute(@rev.object?(@ref.oid)) assert(@obj.null?) + assert_raises(HexaPDF::Error) { @obj.document } end it "marks the object as PDF null object when using mark_as_free=true" do refute(@obj.null?) @rev.delete(@ref) assert(@rev.object(@ref).null?) assert(@obj.null?) + assert_raises(HexaPDF::Error) { @obj.document } end end describe "object iteration" do it "iterates over all objects via each" do