michael@0: Cu.import("resource://services-sync/util.js"); michael@0: michael@0: function run_test() { michael@0: let str; michael@0: michael@0: // we just test whether the returned string includes the michael@0: // string "unknown", should be good enough michael@0: michael@0: str = Utils.getErrorString("error.login.reason.account"); michael@0: do_check_true(str.match(/unknown/i) == null); michael@0: michael@0: str = Utils.getErrorString("foobar"); michael@0: do_check_true(str.match(/unknown/i) != null); michael@0: }