Open melisabok opened 7 years ago
For the first rulings there is a difference of 1, so we get different y in the detected table and the test fails
old: [x=75.0,y=154.0,w=447.0,h=344.0,bottom=498.000000,right=522.000000]
new: [x=75.0,y=155.0,w=446.0,h=343.0,bottom=498.000000,right=521.000000]
and the expected table should be
technology.tabula.Rectangle[x=82.0,y=154.88995,w=400.0,h=338.0,bottom=492.889954,right=482.000000]
because 155 > 154.88 then the test fails because the contains(comparePages) evaluation returns false.
old:
horizontalRulings: [class technology.tabula.Ruling[x1=76.500000 y1=155.250000 x2=520.500000 y2=155.250000], class technology.tabula.Ruling[x1=76.500000 y1=169.000000 x2=520.500000 y2=169.000000], class technology.tabula.Ruling[x1=76.500000 y1=218.250000 x2=520.500000 y2=218.250000], class technology.tabula.Ruling[x1=76.500000 y1=290.750000 x2=520.500000 y2=290.750000], class technology.tabula.Ruling[x1=76.500000 y1=362.750000 x2=520.500000 y2=362.750000], class technology.tabula.Ruling[x1=76.500000 y1=398.750000 x2=520.500000 y2=398.750000], class technology.tabula.Ruling[x1=76.500000 y1=459.250000 x2=520.500000 y2=459.250000], class technology.tabula.Ruling[x1=76.500000 y1=496.500000 x2=520.500000 y2=496.500000]]
new:
horizontalRulings: [class technology.tabula.Ruling[x1=76.250000 y1=156.250000 x2=519.750000 y2=156.250000], class technology.tabula.Ruling[x1=76.250000 y1=169.500000 x2=519.750000 y2=169.500000], class technology.tabula.Ruling[x1=76.250000 y1=219.250000 x2=519.750000 y2=219.250000], class technology.tabula.Ruling[x1=76.250000 y1=291.250000 x2=519.750000 y2=291.250000], class technology.tabula.Ruling[x1=76.250000 y1=363.250000 x2=519.750000 y2=363.250000], class technology.tabula.Ruling[x1=76.250000 y1=399.750000 x2=519.750000 y2=399.750000], class technology.tabula.Ruling[x1=76.250000 y1=459.750000 x2=519.750000 y2=459.750000], class technology.tabula.Ruling[x1=76.250000 y1=497.000000 x2=519.750000 y2=497.000000]]
When changes between master and pdfbox2.0 are this small, just modify the tests's expectation. While making sure that they make semantic sense, of course.
master
pdfbox2.0
https://github.com/melisabok/tabula-java/commit/cf540728aa538fa6b7227a6a92d5ea1268a84359
For the first rulings there is a difference of 1, so we get different y in the detected table and the test fails
old: [x=75.0,y=154.0,w=447.0,h=344.0,bottom=498.000000,right=522.000000]
new: [x=75.0,y=155.0,w=446.0,h=343.0,bottom=498.000000,right=521.000000]
and the expected table should be
technology.tabula.Rectangle[x=82.0,y=154.88995,w=400.0,h=338.0,bottom=492.889954,right=482.000000]
because 155 > 154.88 then the test fails because the contains(comparePages) evaluation returns false.
old:
new: