[Libreoffice-commits] core.git: emfio/qa
Bartosz Kosiorek (via logerrit)
logerrit at kemper.freedesktop.org
Thu May 27 11:10:09 UTC 2021
emfio/qa/cppunit/emf/EmfImportTest.cxx | 8 ++++----
emfio/qa/cppunit/wmf/data/TestPalette.wmf |binary
2 files changed, 4 insertions(+), 4 deletions(-)
New commits:
commit 9cc47eda70025c6bccfad1cfc45d30b7ecd2fc19
Author: Bartosz Kosiorek <gang65 at poczta.onet.pl>
AuthorDate: Thu May 27 10:45:47 2021 +0200
Commit: Bartosz Kosiorek <gang65 at poczta.onet.pl>
CommitDate: Thu May 27 13:09:33 2021 +0200
tdf#117957 WMF Fix failing tests on arm64
So the issue is caused by floating numbers,
On x86_64 it is:
338.499728160392-445.269903703769
on arm it is:
338.499728160392-445.26990370377
As in test files, we have two ellipses (which are made from small lines),
which points rounds differently on different architectures
Change-Id: I10efe80fea0944cf957e949c8c209c94fd588702
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116234
Tested-by: Jenkins
Reviewed-by: Bartosz Kosiorek <gang65 at poczta.onet.pl>
diff --git a/emfio/qa/cppunit/emf/EmfImportTest.cxx b/emfio/qa/cppunit/emf/EmfImportTest.cxx
index b28985a3b165..e825dce810da 100644
--- a/emfio/qa/cppunit/emf/EmfImportTest.cxx
+++ b/emfio/qa/cppunit/emf/EmfImportTest.cxx
@@ -515,25 +515,25 @@ void Test::TestPaletteWMF()
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polypolygoncolor", 2);
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polypolygoncolor[1]/polypolygon",
- "path", "m2433 1216.5c0 213.540351086756-56.2099207528522 423.318631225821-162.98009629623 608.25s-260.338534929591 338.499728160392-445.269903703769 445.26990370377-394.709648913244 162.98009629623-608.25 162.98009629623-423.318631225821-56.2099207528518-608.25-162.98009629623-338.499728160392-260.338534929591-445.26990370377-445.26990370377-162.980096296231-394.709648913244-162.980096296231-608.25c-2.70117261891301E-013-213.540351086756 56.2099207528519-423.318631225821 162.98009629623-608.25 106.770175543378-184.931368774179 260.338534929591-338.499728160392 445.269903703769-445.26990370377s394.709648913244-162.980096296231 608.25-162.980096296231c213.540351086756-5.40234523782601E-013 423.318631225821 56.2099207528518 608.25 162.98009629623s338.499728160392 260.338534929591 445.26990370377 445.269903703769c106.770175543379 184.931368774179 162.980096296231 394.709648913244 162.980096296231 608.25z");
+ "path", "m0 0h3015v3015h-3015z");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polypolygoncolor[1]",
"color", "#ffff00");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polypolygoncolor[2]/polypolygon",
- "path", "m5079 3862.5c0 213.540351086756-56.2099207528527 423.318631225821-162.980096296231 608.25s-260.33853492959 338.499728160391-445.269903703769 445.269903703769-394.709648913244 162.980096296231-608.25 162.980096296231-423.318631225821-56.2099207528518-608.25-162.98009629623-338.499728160391-260.33853492959-445.26990370377-445.269903703769-162.980096296231-394.709648913245-162.980096296231-608.250000000001c-4.54747350886464E-013-213.540351086756 56.2099207528518-423.318631225821 162.98009629623-608.25 106.770175543378-184.931368774179 260.33853492959-338.499728160392 445.269903703769-445.26990370377s394.709648913244-162.980096296231 608.25-162.980096296231c213.540351086756-4.54747350886464E-013 423.318631225821 56.2099207528522 608.25 162.98009629623s338.499728160392 260.33853492959 445.26990370377 445.269903703769c106.770175543378 184.931368774178 162.980096296231 394.709648913244 162.980096296231 608.25z");
+ "path", "m4920 3571c0 236.798958993862-62.332250797861 469.426085921606-180.731730294792 674.5s-288.694355626813 375.368790208277-493.768269705208 493.768269705208-437.701041006137 180.731730294792-674.5 180.731730294792-469.426085921606-62.332250797861-674.5-180.731730294792-375.368790208277-288.694355626812-493.768269705208-493.768269705207-180.731730294792-437.701041006138-180.731730294792-674.5c-4.54747350886464E-013-236.798958993862 62.332250797861-469.426085921606 180.731730294792-674.5 118.399479496931-205.073914078395 288.694355626812-375.368790208277 493.768269705207-493.768269705208s437.701041006138-180.731730294793 674.5-180.731730294793c236.798958993862-4.54747350886464E-013 469.426085921606 62.3322507978601 674.5 180.731730294791s375.368790208277 288.694355626813 493.768269705208 493.768269705207c118.399479496932 205.073914078394 180.731730294793 437.701041006138 180.731730294793 674.5z");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polypolygoncolor[2]",
"color", "#0080ff");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polygonstroke", 2);
assertXPathContent(pDocument, "/primitive2D/metafile/transform/mask/polygonstroke[1]/polygon",
- "2408,1191 2406,1129 2402,1068 2394,1007 2383,946 2369,886 2352,827 2332,768 2309,711 2284,655 2255,600 2224,547 2190,496 2153,446 2114,398 2073,353 2029,309 1984,268 1936,229 1886,192 1835,158 1782,127 1727,98 1671,73 1614,50 1555,30 1496,13 1436,-1 1375,-12 1314,-20 1253,-24 1191,-26 1191,-26 1129,-24 1068,-20 1007,-12 946,-1 886,13 827,30 768,50 711,73 655,98 600,127 547,158 496,192 446,229 398,268 353,309 309,353 268,398 229,446 192,496 158,547 127,600 98,655 73,711 50,768 30,827 13,886 -1,946 -12,1007 -20,1068 -24,1129 -26,1191 -26,1191 -24,1253 -20,1314 -12,1375 -1,1436 13,1496 30,1555 50,1614 73,1671 98,1727 127,1782 158,1835 192,1886 229,1936 268,1984 309,2029 353,2073 398,2114 446,2153 496,2190 547,2224 600,2255 655,2284 711,2309 768,2332 827,2352 886,2369 946,2383 1007,2394 1068,2402 1129,2406 1191,2408 1191,2408 1253,2406 1314,2402 1375,2394 1436,2383 1496,2369 1555,2352 1614,2332 1671,2309 1727,2284 1782,2255 1835,2224 1886,2190 1936,2153 1984,2114
2029,2073 2073,2029 2114,1984 2153,1936 2190,1886 2224,1835 2255,1782 2284,1727 2309,1671 2332,1614 2352,1555 2369,1496 2383,1436 2394,1375 2402,1314 2406,1253");
+ "0,0 3015,0 3015,3015 0,3015");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polygonstroke[1]/line",
"color", "#ff0000");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polygonstroke[1]/line",
"width", "132");
assertXPathContent(pDocument, "/primitive2D/metafile/transform/mask/polygonstroke[2]/polygon",
- "5053,3836 5051,3774 5047,3713 5039,3652 5028,3591 5014,3531 4997,3472 4977,3413 4954,3356 4929,3300 4900,3245 4869,3192 4835,3141 4798,3091 4759,3043 4718,2998 4674,2954 4629,2913 4581,2874 4531,2837 4480,2803 4427,2772 4372,2743 4316,2718 4259,2695 4200,2675 4141,2658 4081,2644 4020,2633 3959,2625 3898,2621 3836,2619 3836,2619 3774,2621 3713,2625 3652,2633 3591,2644 3531,2658 3472,2675 3413,2695 3356,2718 3300,2743 3245,2772 3192,2803 3141,2837 3091,2874 3043,2913 2998,2954 2954,2998 2913,3043 2874,3091 2837,3141 2803,3192 2772,3245 2743,3300 2718,3356 2695,3413 2675,3472 2658,3531 2644,3591 2633,3652 2625,3713 2621,3774 2619,3836 2619,3836 2621,3898 2625,3959 2633,4020 2644,4081 2658,4141 2675,4200 2695,4259 2718,4316 2743,4372 2772,4427 2803,4480 2837,4531 2874,4581 2913,4629 2954,4674 2998,4718 3043,4759 3091,4798 3141,4835 3192,4869 3245,4900 3300,4929 3356,4954 3413,4977 3472,4997 3531,5014 3591,5028 3652,5039 3713,5047 3774,5051 3836,5053 3836,5053 389
8,5051 3959,5047 4020,5039 4081,5028 4141,5014 4200,4997 4259,4977 4316,4954 4372,4929 4427,4900 4480,4869 4531,4835 4581,4798 4629,4759 4674,4718 4718,4674 4759,4629 4798,4581 4835,4531 4869,4480 4900,4427 4929,4372 4954,4316 4977,4259 4997,4200 5014,4141 5028,4081 5039,4020 5047,3959 5051,3898");
+ "4894,3545 4892,3477 4887,3409 4878,3341 4866,3273 4851,3207 4832,3141 4810,3076 4785,3013 4756,2951 4724,2890 4690,2831 4652,2774 4612,2719 4569,2666 4523,2616 4474,2567 4424,2521 4371,2478 4316,2438 4259,2400 4200,2366 4139,2334 4077,2305 4014,2280 3949,2258 3883,2239 3817,2224 3749,2212 3681,2203 3613,2198 3545,2196 3545,2196 3477,2198 3409,2203 3341,2212 3273,2224 3207,2239 3141,2258 3076,2280 3013,2305 2951,2334 2890,2366 2831,2400 2774,2438 2719,2478 2666,2521 2616,2567 2567,2616 2521,2666 2478,2719 2438,2774 2400,2831 2366,2890 2334,2951 2305,3013 2280,3076 2258,3141 2239,3207 2224,3273 2212,3341 2203,3409 2198,3477 2196,3545 2196,3545 2198,3613 2203,3681 2212,3749 2224,3817 2239,3883 2258,3949 2280,4014 2305,4077 2334,4139 2366,4200 2400,4259 2438,4316 2478,4371 2521,4424 2567,4474 2616,4523 2666,4569 2719,4612 2774,4652 2831,4690 2890,4724 2951,4756 3013,4785 3076,4810 3141,4832 3207,4851 3273,4866 3341,4878 3409,4887 3477,4892 3545,4894 3545,4894 361
3,4892 3681,4887 3749,4878 3817,4866 3883,4851 3949,4832 4014,4810 4077,4785 4139,4756 4200,4724 4259,4690 4316,4652 4371,4612 4424,4569 4474,4523 4523,4474 4569,4424 4612,4371 4652,4316 4690,4259 4724,4200 4756,4139 4785,4077 4810,4014 4832,3949 4851,3883 4866,3817 4878,3749 4887,3681 4892,3613");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polygonstroke[2]/line",
"color", "#ff0000");
assertXPath(pDocument, "/primitive2D/metafile/transform/mask/polygonstroke[2]/line",
diff --git a/emfio/qa/cppunit/wmf/data/TestPalette.wmf b/emfio/qa/cppunit/wmf/data/TestPalette.wmf
index 222809df5ff9..013adeb16de7 100644
Binary files a/emfio/qa/cppunit/wmf/data/TestPalette.wmf and b/emfio/qa/cppunit/wmf/data/TestPalette.wmf differ
More information about the Libreoffice-commits
mailing list