In https://chromium-review.googlesource.com/c/chromium/src/+/665300, testharnessreport changed so that any \n's in the output are escaped.
However, this makes webaudio failures much harder to read. With the new behavior, we get something like:
PASS > [440 Hz Osc]
FAIL X [0,0.00013090006541460752,0.00026180013082921505,0.0003927001671399921,0.0005236002616584301,0.0006545003852806985,0.0007854003924876451,0.0009163003414869308,0.0010472005233168602,0.0011781005887314677,0.0013090005377307534,0.0014399007195606828,0.0015708007849752903,0.0017017008503898978,0.0018326009158045053,0.001963500864803791...] does not equal [0,0.05756402015686035,0.11493715643882751,0.1719290316104889,0.22835081815719604,0.2840152978897095,0.3387379050254822,0.39233702421188354,0.4446350336074829,0.49545854330062866,0.5446388125419617,0.5920130610466003,0.6374237537384033,0.6807207465171814,0.7217600345611572,0.7604057788848877...] with an element-wise tolerance of {"absoluteThreshold":0,"relativeThreshold":0}.\n Index Actual Expected AbsError RelError Test threshold\n [1] 1.3090006541460752e-4 5.7564020156860352e-2 5.7433120091445744e-2 9.9772600897126529e-1 0.0000000000000000e+0\n [2] 2.6180013082921505e-4 1.1493715643882751e-1 1.1467535630799830e-1 9.9772223240124658e-1 0.0000000000000000e+0\n [3] 3.9270016713999212e-4 1.7192903161048889e-1 1.7153633144334890e-1 9.9771591706495699e-1 0.0000000000000000e+0\n [4] 5.2360026165843010e-4 2.2835081815719604e-1 2.2782721789553761e-1 9.9770703575365349e-1 0.0000000000000000e+0\n [5] 6.5450038528069854e-4 2.8401529788970947e-1 2.8336079750442877e-1 9.9769554530990490e-1 0.0000000000000000e+0\n ...and 47994 more errors.\n Max AbsError of 1.9998876452445984e+0 at index of 12082.\n [12082] 9.9994242191314697e-1 -9.9994522333145142e-1 1.9998876452445984e+0 1.9999971984282348e+0 0.0000000000000000e+0\n Max RelError of 5.9855878902260316e+4 at index of 600.\n [600] 7.8459098935127258e-2 1.3107783161103725e-6 7.8457788156811148e-2 5.9855878902260316e+4 0.0000000000000000e+0\n assert_true: expected true got false
FAIL X NaN is not greater than or equal to 1000. Got NaN. assert_true: expected true got false
With the old behavior (without escaping) we get:
FAIL X [0,0.00013090006541460752,0.00026180013082921505,0.0003927001671399921,0.0005236002616584301,0.0006545003852806985,0.0007854003924876451,0.0009163003414869308,0.0010472005233168602,0.0011781005887314677,0.0013090005377307534,0.0014399007195606828,0.0015708007849752903,0.0017017008503898978,0.0018326009158045053,0.001963500864803791...] does not equal [0,0.05756402015686035,0.11493715643882751,0.1719290316104889,0.22835081815719604,0.2840152978897095,0.3387379050254822,0.39233702421188354,0.4446350336074829,0.49545854330062866,0.5446388125419617,0.5920130610466003,0.6374237537384033,0.6807207465171814,0.7217600345611572,0.7604057788848877...] with an element-wise tolerance of {"absoluteThreshold":0,"relativeThreshold":0}.
Index Actual Expected AbsError RelError Test threshold
[1] 1.3090006541460752e-4 5.7564020156860352e-2 5.7433120091445744e-2 9.9772600897126529e-1 0.0000000000000000e+0
[2] 2.6180013082921505e-4 1.1493715643882751e-1 1.1467535630799830e-1 9.9772223240124658e-1 0.0000000000000000e+0
[3] 3.9270016713999212e-4 1.7192903161048889e-1 1.7153633144334890e-1 9.9771591706495699e-1 0.0000000000000000e+0
[4] 5.2360026165843010e-4 2.2835081815719604e-1 2.2782721789553761e-1 9.9770703575365349e-1 0.0000000000000000e+0
[5] 6.5450038528069854e-4 2.8401529788970947e-1 2.8336079750442877e-1 9.9769554530990490e-1 0.0000000000000000e+0
...and 47994 more errors.
Max AbsError of 1.9998876452445984e+0 at index of 12082.
[12082] 9.9994242191314697e-1 -9.9994522333145142e-1 1.9998876452445984e+0 1.9999971984282348e+0 0.0000000000000000e+0
Max RelError of 5.9855878902260316e+4 at index of 600.
[600] 7.8459098935127258e-2 1.3107783161103725e-6 7.8457788156811148e-2 5.9855878902260316e+4 0.0000000000000000e+0
(Not sure if this shows up quite right here, but the important thing is the the new version has the failure message all smashed onto one line, and the old behavior has nice columns.)
We carefully arranged the failure case to print out nice columns to make it easier to understand what happened, and to print out the max abserror and relerror to make it easy to figure out how to update the test thresholds.
Comment 1 by qyears...@chromium.org
, Oct 10 2017