B2G/gecko/toolkit/components/social/test/browser/browser_notifications.js
// end of alerts service mock.
end of alerts service mock.
end of alerts service mock .
function ensureProvider(workerFunction, cb) {
  let manifest = {
    origin: TEST_PROVIDER_ORIGIN,
    name: "Example Provider",
    workerURL: "data:application/javascript;charset=utf-8," + encodeURI("let run=" + workerFunction.toSource()) + ";run();"
  };
  ensureSocialEnabled();
  SocialService.addProvider(manifest, function (p) {
    cb(p);
  });
}
function ensureProvider ( workerFunction , cb ) { let manifest = { origin : TEST_PROVIDER_ORIGIN , name : "Example Provider" , workerURL : "data:application/javascript;charset=utf-8," + encodeURI ( "let run=" + workerFunction . toSource ( ) ) + ";run();" } ; ensureSocialEnabled ( ) ; SocialService . addProvider ( manifest , function ( p ) { cb ( p ) ; } ) ; }
end of alerts service mock.
end of alerts service mock .