Bug 1308437 - Part 3: Change expected error to TypeError when testing setValueCurveAtTime with non-finite elements in TestAudioEventTimeline.cpp. r=dminor, a=padenot
authorBeekill95 <nnn_bikiu0707@yahoo.com>
Tue, 07 Feb 2017 22:12:06 +0700
changeset 370499 9066a2ed849311d798300629edac248e81978af5
parent 370498 845451c03a199550c060f4b1866d35da58f97093
child 370500 f99ea4baeaff2ee4c049eb2aaf273f6c50620cfe
push id10863
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 23:02:23 +0000
treeherdermozilla-aurora@0931190cd725 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdminor, padenot
bugs1308437
milestone54.0a1
Bug 1308437 - Part 3: Change expected error to TypeError when testing setValueCurveAtTime with non-finite elements in TestAudioEventTimeline.cpp. r=dminor, a=padenot
dom/media/webaudio/gtest/TestAudioEventTimeline.cpp
--- a/dom/media/webaudio/gtest/TestAudioEventTimeline.cpp
+++ b/dom/media/webaudio/gtest/TestAudioEventTimeline.cpp
@@ -198,21 +198,21 @@ TEST(AudioEventTimeline, InvalidEvents)
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
   timeline.SetTargetAtTime(0.4f, Infinity, 1.0, rv);
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
   timeline.SetTargetAtTime(0.4f, -Infinity, 1.0, rv);
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(nullptr, 0, 1.0, 1.0, rv);
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(badCurve1, ArrayLength(badCurve1), 1.0, 1.0, rv);
-  is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
+  is(rv, NS_ERROR_TYPE_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(badCurve2, ArrayLength(badCurve2), 1.0, 1.0, rv);
-  is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
+  is(rv, NS_ERROR_TYPE_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(badCurve3, ArrayLength(badCurve3), 1.0, 1.0, rv);
-  is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
+  is(rv, NS_ERROR_TYPE_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(curve, ArrayLength(curve), NaN, 1.0, rv);
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(curve, ArrayLength(curve), Infinity, 1.0, rv);
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(curve, ArrayLength(curve), -Infinity, 1.0, rv);
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");
   timeline.SetValueCurveAtTime(curve, ArrayLength(curve), 1.0, NaN, rv);
   is(rv, NS_ERROR_DOM_SYNTAX_ERR, "Correct error code returned");