Bug 1408044 - stop using about.dtd as an example in firefox-ui/puppeteer/marionette docs/tests, r=whimboo
☠☠ backed out by 19229263df31 ☠ ☠
authorGijs Kruitbosch <gijskruitbosch@gmail.com>
Tue, 14 Nov 2017 23:37:04 +0000
changeset 436928 5131400190142ce57036f9e1d50db2324d981ac8
parent 436841 249a8177ad915734b83c357d49213e26d889b377
child 436929 10fc0a581606e5a501ab91b66046ed50fdfcf59a
push id117
push userfmarier@mozilla.com
push dateTue, 28 Nov 2017 20:17:16 +0000
reviewerswhimboo
bugs1408044
milestone59.0a1
Bug 1408044 - stop using about.dtd as an example in firefox-ui/puppeteer/marionette docs/tests, r=whimboo MozReview-Commit-ID: 4zog9pSgCs9
testing/firefox-ui/tests/puppeteer/test_l10n.py
testing/marionette/client/marionette_driver/localization.py
testing/marionette/driver.js
testing/marionette/l10n.js
--- a/testing/firefox-ui/tests/puppeteer/test_l10n.py
+++ b/testing/firefox-ui/tests/puppeteer/test_l10n.py
@@ -12,28 +12,28 @@ from marionette_harness import Marionett
 class TestL10n(PuppeteerMixin, MarionetteTestCase):
 
     def setUp(self):
         super(TestL10n, self).setUp()
 
         self.l10n = L10n(self.marionette)
 
     def test_dtd_entity_chrome(self):
-        dtds = ['chrome://global/locale/about.dtd',
+        dtds = ['chrome://branding/locale/brand.dtd',
                 'chrome://browser/locale/baseMenuOverlay.dtd']
 
         value = self.l10n.localize_entity(dtds, 'helpSafeMode.label')
         elm = self.marionette.find_element(By.ID, 'helpSafeMode')
         self.assertEqual(value, elm.get_attribute('label'))
 
         self.assertRaises(NoSuchElementException,
                           self.l10n.localize_entity, dtds, 'notExistent')
 
     def test_dtd_entity_content(self):
-        dtds = ['chrome://global/locale/about.dtd',
+        dtds = ['chrome://branding/locale/brand.dtd',
                 'chrome://global/locale/aboutSupport.dtd']
 
         value = self.l10n.localize_entity(dtds, 'aboutSupport.pageTitle')
 
         self.marionette.set_context(self.marionette.CONTEXT_CONTENT)
         self.marionette.navigate('about:support')
 
         elm = self.marionette.find_element(By.TAG_NAME, 'h1')
--- a/testing/marionette/client/marionette_driver/localization.py
+++ b/testing/marionette/client/marionette_driver/localization.py
@@ -12,17 +12,17 @@ class L10n(object):
     .property files. Both types of elements can be identifed via a unique id,
     and the translated content retrieved.
 
     For example::
 
         from marionette_driver.localization import L10n
         l10n = L10n(marionette)
 
-        l10n.localize_entity(["chrome://global/locale/about.dtd"], "about.version")
+        l10n.localize_entity(["chrome://branding/locale/brand.dtd"], "brandShortName")
         l10n.localize_property(["chrome://global/locale/findbar.properties"], "FastFind"))
 
     .. _localization: https://mzl.la/2eUMjyF
     """
 
     def __init__(self, marionette):
         self._marionette = marionette
 
--- a/testing/marionette/driver.js
+++ b/testing/marionette/driver.js
@@ -3491,17 +3491,17 @@ GeckoDriver.prototype.responseCompleted 
     this.curBrowser.pendingCommands = [];
   }
 };
 
 /**
  * Retrieve the localized string for the specified entity id.
  *
  * Example:
- *     localizeEntity(["chrome://global/locale/about.dtd"], "about.version")
+ *     localizeEntity(["chrome://branding/locale/brand.dtd"], "brandShortName")
  *
  * @param {Array.<string>} urls
  *     Array of .dtd URLs.
  * @param {string} id
  *     The ID of the entity to retrieve the localized string for.
  *
  * @return {string}
  *     The localized string for the requested entity.
--- a/testing/marionette/l10n.js
+++ b/testing/marionette/l10n.js
@@ -30,17 +30,17 @@ this.EXPORTED_SYMBOLS = ["l10n"];
 
 /** @namespace */
 this.l10n = {};
 
 /**
  * Retrieve the localized string for the specified entity id.
  *
  * Example:
- *     localizeEntity(["chrome://global/locale/about.dtd"], "about.version")
+ *     localizeEntity(["chrome://branding/locale/brand.dtd"], "brandShortName")
  *
  * @param {Array.<string>} urls
  *     Array of .dtd URLs.
  * @param {string} id
  *     The ID of the entity to retrieve the localized string for.
  *
  * @return {string}
  *     The localized string for the requested entity.