gecko-dev/browser/components/loop/test/mochitest/browser_mozLoop_pluralStrings.js
Jared Wein 32f1127925 Bug 1048882 follow-up - Change the string ID of feedback_window_will_close_in. r=standard8
--HG--
extra : rebase_source : 258a4aa681f6782f8e39302d14c3693d3adc2a2d
2014-08-29 12:43:27 -04:00

19 lines
748 B
JavaScript

/* Any copyright is dedicated to the Public Domain.
http://creativecommons.org/publicdomain/zero/1.0/ */
/**
* This is an integration test from navigator.mozLoop through to the end
* effects - rather than just testing MozLoopAPI alone.
*/
add_task(loadLoopPanel);
add_task(function* test_mozLoop_pluralStrings() {
Assert.ok(gMozLoopAPI, "mozLoop should exist");
var strings = JSON.parse(gMozLoopAPI.getStrings("feedback_window_will_close_in2"));
Assert.equal(gMozLoopAPI.getPluralForm(0, strings.textContent),
"This window will close in {{countdown}} seconds");
Assert.equal(gMozLoopAPI.getPluralForm(1, strings.textContent),
"This window will close in {{countdown}} second");
});