diff --git a/last_commit.txt b/last_commit.txt index 3ece15fce3..fbeb775ed4 100644 --- a/last_commit.txt +++ b/last_commit.txt @@ -1,38 +1,83 @@ -Repository: Products.CMFPlone +Repository: plone.app.upgrade -Branch: refs/heads/5.1.x -Date: 2018-08-29T19:58:39+02:00 -Author: Maurits van Rees (mauritsvanrees) -Commit: https://github.com/plone/Products.CMFPlone/commit/8683c0d377b449b7c52d76cce262f8f4a7c0aae2 +Branch: refs/heads/master +Date: 2018-09-06T18:21:00+02:00 +Author: Sune Broendum Woeller (sunew) +Commit: https://github.com/plone/plone.app.upgrade/commit/6bab181c2ad6b35ccdf56dce46c0ee0bd541ca4c -Fixed the combine-bundles import step to work with keyword in registry directory. +remove the jquery-highlightsearchterms resource, and the - now empty - plone_ecmascript skin layer. See https://github.com/plone/Products.CMFPlone/pull/1963/commits and https://github.com/plone/Products.CMFPlone/issues/1811 https://github.com/plone/Products.CMFPlone/issues/1801 -Issue https://github.com/plone/Products.CMFPlone/issues/2502 +removing records (wip) + +remove jquery-highlightsearchterms from the plone-legacy bundle + +c Files changed: +A plone/app/upgrade/v52/profiles/to_alpha1/registry.xml M CHANGES.rst -M Products/CMFPlone/resources/exportimport/bundles.py -M Products/CMFPlone/tests/test_metabundles.py +M plone/app/upgrade/v52/alphas.py +M plone/app/upgrade/v52/profiles/to_alpha1/skins.xml + +b'diff --git a/CHANGES.rst b/CHANGES.rst\nindex a2d6039e..52b6a681 100644\n--- a/CHANGES.rst\n+++ b/CHANGES.rst\n@@ -13,6 +13,9 @@ New features:\n - Add upgrade steps for Datatbles on Plone 5.1.4\n [frapell]\n \n+- Add upgrade step removing the jquery-highlightsearchterms resource\n+ and the plone_ecmascript skin layer, on Plone 5.2\n+\n Bug fixes:\n \n - *add item here*\ndiff --git a/plone/app/upgrade/v52/alphas.py b/plone/app/upgrade/v52/alphas.py\nindex 774a4b9d..972ee8a7 100644\n--- a/plone/app/upgrade/v52/alphas.py\n+++ b/plone/app/upgrade/v52/alphas.py\n@@ -1,7 +1,9 @@\n # -*- coding: utf-8 -*-\n from plone.app.upgrade.utils import cleanUpSkinsTool\n from plone.app.upgrade.utils import loadMigrationProfile\n+from plone.registry.interfaces import IRegistry\n from Products.CMFCore.utils import getToolByName\n+from zope.component import getUtility\n \n import logging\n \n@@ -13,3 +15,9 @@ def to52alpha1(context):\n loadMigrationProfile(context, \'profile-plone.app.upgrade.v52:to52alpha1\')\n portal = getToolByName(context, \'portal_url\').getPortalObject()\n cleanUpSkinsTool(portal)\n+\n+ registry = getUtility(IRegistry)\n+ record = \'plone.bundles/plone-legacy.resources\'\n+ resources = registry.records[record]\n+ if u\'jquery-highlightsearchterms\' in resources.value:\n+ resources.value.remove(u\'jquery-highlightsearchterms\')\ndiff --git a/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml b/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml\nnew file mode 100644\nindex 00000000..7a2f4c07\n--- /dev/null\n+++ b/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml\n@@ -0,0 +1,24 @@\n+\n+\n+\n+\n+ \n+ \n+\n+ \n+ \n+ 2018-09-06 00:00:00\n+ \n+ \n+ 2018-09-06 00:00:00\n+ \n+\n+\ndiff --git a/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml b/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml\nindex c0d3ddf6..12509b31 100644\n--- a/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml\n+++ b/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml\n@@ -8,4 +8,12 @@\n \n \n \n+ \n+ \n+ \n+ \n \n' + +Repository: plone.app.upgrade + + +Branch: refs/heads/master +Date: 2018-09-06T20:23:08+02:00 +Author: Sune Broendum Woeller (sunew) +Commit: https://github.com/plone/plone.app.upgrade/commit/c979968ea4122e496a0fcd368dbd01dbea443d69 + +Also remove the jquery-highlightsearchterms resource, and the plone_ecmascript skin layer for plone 5.1.4 + +Files changed: +A plone/app/upgrade/v51/profiles/to_514/skins.xml +M CHANGES.rst +M plone/app/upgrade/v51/configure.zcml +M plone/app/upgrade/v51/final.py +M plone/app/upgrade/v51/profiles/to_514/registry.xml + +b'diff --git a/CHANGES.rst b/CHANGES.rst\nindex 52b6a681..45c9b7e6 100644\n--- a/CHANGES.rst\n+++ b/CHANGES.rst\n@@ -14,7 +14,7 @@ New features:\n [frapell]\n \n - Add upgrade step removing the jquery-highlightsearchterms resource\n- and the plone_ecmascript skin layer, on Plone 5.2\n+ and the plone_ecmascript skin layer, on Plone 5.2 and 5.1.4\n \n Bug fixes:\n \ndiff --git a/plone/app/upgrade/v51/configure.zcml b/plone/app/upgrade/v51/configure.zcml\nindex a56c241f..113678a9 100644\n--- a/plone/app/upgrade/v51/configure.zcml\n+++ b/plone/app/upgrade/v51/configure.zcml\n@@ -265,7 +265,7 @@ Add image scaling options to image handling control panel.\n \n \n \ndiff --git a/plone/app/upgrade/v51/final.py b/plone/app/upgrade/v51/final.py\nindex c6e9a498..8960caea 100644\n--- a/plone/app/upgrade/v51/final.py\n+++ b/plone/app/upgrade/v51/final.py\n@@ -1,6 +1,9 @@\n # -*- coding: utf-8 -*-\n+from plone.app.upgrade.utils import cleanUpSkinsTool\n+from plone.registry.interfaces import IRegistry\n from Products.CMFCore.utils import getToolByName\n from zExceptions import BadRequest\n+from zope.component import getUtility\n \n import logging\n \n@@ -38,3 +41,14 @@ def fix_i18n_domain(context):\n \'Action object/%s does not have an i18n_domain property\',\n action_id,\n )\n+\n+\n+def remove_highlightsearchterms(context):\n+ portal = getToolByName(context, \'portal_url\').getPortalObject()\n+ cleanUpSkinsTool(portal)\n+\n+ registry = getUtility(IRegistry)\n+ record = \'plone.bundles/plone-legacy.resources\'\n+ resources = registry.records[record]\n+ if u\'jquery-highlightsearchterms\' in resources.value:\n+ resources.value.remove(u\'jquery-highlightsearchterms\')\ndiff --git a/plone/app/upgrade/v51/profiles/to_514/registry.xml b/plone/app/upgrade/v51/profiles/to_514/registry.xml\nindex 83ad3c05..1b660148 100644\n--- a/plone/app/upgrade/v51/profiles/to_514/registry.xml\n+++ b/plone/app/upgrade/v51/profiles/to_514/registry.xml\n@@ -105,18 +105,23 @@\n ++plone++static/components/datatables.net-select/js/dataTables.select.min.js\n \n \n+ \n+ \n+\n \n \n- 2018-07-10 00:00:00\n+ 2018-09-06 00:00:00\n \n \n- 2018-07-10 00:00:00\n+ 2018-09-06 00:00:00\n \n \n \ndiff --git a/plone/app/upgrade/v51/profiles/to_514/skins.xml b/plone/app/upgrade/v51/profiles/to_514/skins.xml\nnew file mode 100644\nindex 00000000..3e7c38da\n--- /dev/null\n+++ b/plone/app/upgrade/v51/profiles/to_514/skins.xml\n@@ -0,0 +1,11 @@\n+\n+\n+ \n+ \n+ \n+ \n+\n' + +Repository: plone.app.upgrade + + +Branch: refs/heads/master +Date: 2018-09-08T12:26:59+02:00 +Author: Sune Broendum Woeller (sunew) +Commit: https://github.com/plone/plone.app.upgrade/commit/0c1c1ee77c3492da2d3bb74b65e0d6e714c6133c + +Update the compilation date of the plone-legacy bundle, to force recompilation + +Files changed: +M plone/app/upgrade/v51/profiles/to_514/registry.xml +M plone/app/upgrade/v52/profiles/to_alpha1/registry.xml -b'diff --git a/CHANGES.rst b/CHANGES.rst\nindex ff85510b2..231b2da37 100644\n--- a/CHANGES.rst\n+++ b/CHANGES.rst\n@@ -19,6 +19,10 @@ New features:\n \n Bug fixes:\n \n+- Let the ``combine-bundles`` import step also work when the ``IBundleRegistry`` keyword is not in ``registry.xml``, but in a ``registry`` directory.\n+ `Issue 2520 `_.\n+ [maurits]\n+\n - Get rid of obsolete ``X-UA-Compatible`` header.\n [hvelarde]\n \ndiff --git a/Products/CMFPlone/resources/exportimport/bundles.py b/Products/CMFPlone/resources/exportimport/bundles.py\nindex 54e50f79f..c5c78cd33 100644\n--- a/Products/CMFPlone/resources/exportimport/bundles.py\n+++ b/Products/CMFPlone/resources/exportimport/bundles.py\n@@ -14,22 +14,37 @@ def combine(context):\n logger.info("Cannot find registry")\n return\n \n- body = context.readDataFile(\'registry.xml\')\n- if body and "IBundleRegistry" in body:\n- # Calling combine_bundles will have as side effect that the\n- # Content-Type header of the response is set to application/javascript,\n- # which we do not want. So we reset it to the original at the end.\n- site = context.getSite()\n- request = getattr(site, \'REQUEST\', getRequest())\n- if request is not None:\n- # Easily happens in tests.\n- orig_header = request.response.getHeader(\'Content-Type\')\n- combine_bundles(site)\n- if request is not None:\n- new_header = request.response.getHeader(\'Content-Type\')\n- if new_header != orig_header:\n- if orig_header is None:\n- # Setting it to None would result in the string \'None\'.\n- # So pick a saner one.\n- orig_header = \'text/html\'\n- request.response.setHeader(\'Content-Type\', orig_header)\n+ # Look for a keyword in registry.xml or the registry directory.\n+ filepaths = [\'registry.xml\']\n+ if context.isDirectory(\'registry\'):\n+ for filename in context.listDirectory(\'registry\'):\n+ filepaths.append(\'registry/\' + filename)\n+ found = False\n+ for filepath in filepaths:\n+ body = context.readDataFile(filepath)\n+ if body is not None and \'IBundleRegistry\' in body:\n+ found = True\n+ break\n+ if not found:\n+ return\n+\n+ # Calling combine_bundles will have as side effect that the\n+ # Content-Type header of the response is set to application/javascript,\n+ # which we do not want. So we reset it to the original at the end.\n+ site = context.getSite()\n+ request = getattr(site, \'REQUEST\', getRequest())\n+ # In tests the request can easily be None.\n+ if request is not None:\n+ orig_header = request.response.getHeader(\'Content-Type\')\n+ combine_bundles(site)\n+ if request is None:\n+ # we are done\n+ return\n+ new_header = request.response.getHeader(\'Content-Type\')\n+ if new_header == orig_header:\n+ return\n+ if orig_header is None:\n+ # Setting it to None would result in the string \'None\'.\n+ # So pick a saner one.\n+ orig_header = \'text/html\'\n+ request.response.setHeader(\'Content-Type\', orig_header)\ndiff --git a/Products/CMFPlone/tests/test_metabundles.py b/Products/CMFPlone/tests/test_metabundles.py\nindex 3b29e6c63..038a4e2b9 100644\n--- a/Products/CMFPlone/tests/test_metabundles.py\n+++ b/Products/CMFPlone/tests/test_metabundles.py\n@@ -10,6 +10,20 @@\n PRODUCTION_RESOURCE_DIRECTORY,\n combine_bundles,\n )\n+from Products.GenericSetup.tests import common\n+\n+\n+class DummyImportContext(common.DummyImportContext):\n+ # Copied from plone.app.registry tests.\n+ # This expands the context with directories.\n+\n+ _directories = {}\n+\n+ def listDirectory(self, path):\n+ return self._directories.get(path, [])\n+\n+ def isDirectory(self, path):\n+ return path in self._directories\n \n \n class ProductsCMFPloneSetupTest(PloneTestCase):\n@@ -51,3 +65,76 @@ def test_overrides(self):\n \'alert("Overrided legacy!");\',\n self.production_folder.readFile(\'default.js\')\n )\n+\n+ def test_import(self):\n+ # If IBundleRegistry is in registry.xml, the combine-bundles import step\n+ # will call combine_bundles.\n+ from Products.CMFPlone.resources.exportimport.bundles import combine\n+ # from Products.CMFPlone.resources.browser.combine import get_override_directory\n+ # from Products.CMFPlone.resources.browser.combine import PRODUCTION_RESOURCE_DIRECTORY\n+\n+ # Prepare some registry xml files with or without the key IBundleRegistry.\n+ xml_with = \'with IBundleRegistry\'\n+ xml_without = \'without bundle registry\'\n+ xml_without2 = \'without bundle registry\'\n+ context = DummyImportContext(self.portal, purge=False)\n+\n+ def get_timestamp():\n+ # If combine_bundles is run, a timestamp is updated.\n+ return self.production_folder.readFile(\'timestamp.txt\')\n+\n+ ts1 = get_timestamp()\n+ self.assertTrue(ts1)\n+\n+ # call the import step on a file without bundles\n+ context._files = {\'registry.xml\': xml_without}\n+ combine(context)\n+ ts2 = get_timestamp()\n+ self.assertEqual(ts1, ts2)\n+\n+ # call the import step on a file with bundles\n+ context._files = {\'registry.xml\': xml_with}\n+ combine(context)\n+ ts3 = get_timestamp()\n+ self.assertLess(ts2, ts3)\n+\n+ # call the import step on a file without bundles\n+ context._files = {\'registry.xml\': xml_without2}\n+ combine(context)\n+ ts4 = get_timestamp()\n+ self.assertEqual(ts3, ts4)\n+\n+ # Since Plone 5.1 the registry xml can also be a directory.\n+ # Set one file with bundles.\n+ context._files = {\n+ \'registry.xml\': xml_without,\n+ \'registry/foo2.xml\': xml_with,\n+ \'registry/foo3.xml\': xml_without2,\n+ }\n+ context._directories = {\n+ \'registry\': [\n+ \'foo2.xml\',\n+ \'foo3.xml\',\n+ ]\n+ }\n+ combine(context)\n+ ts10 = get_timestamp()\n+ self.assertLess(ts4, ts10)\n+\n+ # The registry.xml file itself may be missing.\n+ context._files = {\n+ \'registry/foo2.xml\': xml_with,\n+ \'registry/foo3.xml\': xml_without2,\n+ }\n+ combine(context)\n+ ts11 = get_timestamp()\n+ self.assertLess(ts10, ts11)\n+\n+ # Now without any bundle info.\n+ context._files = {\n+ \'registry/foo2.xml\': xml_without,\n+ \'registry/foo3.xml\': xml_without2,\n+ }\n+ combine(context)\n+ ts12 = get_timestamp()\n+ self.assertEqual(ts11, ts12)\n' +b'diff --git a/plone/app/upgrade/v51/profiles/to_514/registry.xml b/plone/app/upgrade/v51/profiles/to_514/registry.xml\nindex 1b660148..ef3704aa 100644\n--- a/plone/app/upgrade/v51/profiles/to_514/registry.xml\n+++ b/plone/app/upgrade/v51/profiles/to_514/registry.xml\n@@ -124,4 +124,10 @@\n 2018-09-06 00:00:00\n \n \n+ \n+ \n+ \n+ \n+\n \ndiff --git a/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml b/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml\nindex 7a2f4c07..6582f962 100644\n--- a/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml\n+++ b/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml\n@@ -7,18 +7,10 @@\n remove="True">\n \n \n- \n- \n- 2018-09-06 00:00:00\n- \n- \n- 2018-09-06 00:00:00\n+ \n+ \n+ \n \n \n \n' -Repository: Products.CMFPlone +Repository: plone.app.upgrade -Branch: refs/heads/5.1.x -Date: 2018-09-06T10:08:15+02:00 +Branch: refs/heads/master +Date: 2018-09-09T08:41:13+02:00 Author: Jens W. Klein (jensens) -Commit: https://github.com/plone/Products.CMFPlone/commit/9d900bbc9146195c90bcfc8982058f8f68a3b667 +Commit: https://github.com/plone/plone.app.upgrade/commit/8d8f25df6bc28121d99bae26d852de5f546853cb -Merge pull request #2503 from plone/issue-2502-51-combine-bundles-registry-directory +Merge pull request #170 from plone/remove-highlightsearchterms -Fixed combine-bundles step to work with keyword in registry directory. +Remove jquery-highlightsearchterms and plone_ecmascript layer Files changed: +A plone/app/upgrade/v51/profiles/to_514/skins.xml +A plone/app/upgrade/v52/profiles/to_alpha1/registry.xml M CHANGES.rst -M Products/CMFPlone/resources/exportimport/bundles.py -M Products/CMFPlone/tests/test_metabundles.py +M plone/app/upgrade/v51/configure.zcml +M plone/app/upgrade/v51/final.py +M plone/app/upgrade/v51/profiles/to_514/registry.xml +M plone/app/upgrade/v52/alphas.py +M plone/app/upgrade/v52/profiles/to_alpha1/skins.xml -b'diff --git a/CHANGES.rst b/CHANGES.rst\nindex ff85510b2..231b2da37 100644\n--- a/CHANGES.rst\n+++ b/CHANGES.rst\n@@ -19,6 +19,10 @@ New features:\n \n Bug fixes:\n \n+- Let the ``combine-bundles`` import step also work when the ``IBundleRegistry`` keyword is not in ``registry.xml``, but in a ``registry`` directory.\n+ `Issue 2520 `_.\n+ [maurits]\n+\n - Get rid of obsolete ``X-UA-Compatible`` header.\n [hvelarde]\n \ndiff --git a/Products/CMFPlone/resources/exportimport/bundles.py b/Products/CMFPlone/resources/exportimport/bundles.py\nindex 54e50f79f..c5c78cd33 100644\n--- a/Products/CMFPlone/resources/exportimport/bundles.py\n+++ b/Products/CMFPlone/resources/exportimport/bundles.py\n@@ -14,22 +14,37 @@ def combine(context):\n logger.info("Cannot find registry")\n return\n \n- body = context.readDataFile(\'registry.xml\')\n- if body and "IBundleRegistry" in body:\n- # Calling combine_bundles will have as side effect that the\n- # Content-Type header of the response is set to application/javascript,\n- # which we do not want. So we reset it to the original at the end.\n- site = context.getSite()\n- request = getattr(site, \'REQUEST\', getRequest())\n- if request is not None:\n- # Easily happens in tests.\n- orig_header = request.response.getHeader(\'Content-Type\')\n- combine_bundles(site)\n- if request is not None:\n- new_header = request.response.getHeader(\'Content-Type\')\n- if new_header != orig_header:\n- if orig_header is None:\n- # Setting it to None would result in the string \'None\'.\n- # So pick a saner one.\n- orig_header = \'text/html\'\n- request.response.setHeader(\'Content-Type\', orig_header)\n+ # Look for a keyword in registry.xml or the registry directory.\n+ filepaths = [\'registry.xml\']\n+ if context.isDirectory(\'registry\'):\n+ for filename in context.listDirectory(\'registry\'):\n+ filepaths.append(\'registry/\' + filename)\n+ found = False\n+ for filepath in filepaths:\n+ body = context.readDataFile(filepath)\n+ if body is not None and \'IBundleRegistry\' in body:\n+ found = True\n+ break\n+ if not found:\n+ return\n+\n+ # Calling combine_bundles will have as side effect that the\n+ # Content-Type header of the response is set to application/javascript,\n+ # which we do not want. So we reset it to the original at the end.\n+ site = context.getSite()\n+ request = getattr(site, \'REQUEST\', getRequest())\n+ # In tests the request can easily be None.\n+ if request is not None:\n+ orig_header = request.response.getHeader(\'Content-Type\')\n+ combine_bundles(site)\n+ if request is None:\n+ # we are done\n+ return\n+ new_header = request.response.getHeader(\'Content-Type\')\n+ if new_header == orig_header:\n+ return\n+ if orig_header is None:\n+ # Setting it to None would result in the string \'None\'.\n+ # So pick a saner one.\n+ orig_header = \'text/html\'\n+ request.response.setHeader(\'Content-Type\', orig_header)\ndiff --git a/Products/CMFPlone/tests/test_metabundles.py b/Products/CMFPlone/tests/test_metabundles.py\nindex 3b29e6c63..038a4e2b9 100644\n--- a/Products/CMFPlone/tests/test_metabundles.py\n+++ b/Products/CMFPlone/tests/test_metabundles.py\n@@ -10,6 +10,20 @@\n PRODUCTION_RESOURCE_DIRECTORY,\n combine_bundles,\n )\n+from Products.GenericSetup.tests import common\n+\n+\n+class DummyImportContext(common.DummyImportContext):\n+ # Copied from plone.app.registry tests.\n+ # This expands the context with directories.\n+\n+ _directories = {}\n+\n+ def listDirectory(self, path):\n+ return self._directories.get(path, [])\n+\n+ def isDirectory(self, path):\n+ return path in self._directories\n \n \n class ProductsCMFPloneSetupTest(PloneTestCase):\n@@ -51,3 +65,76 @@ def test_overrides(self):\n \'alert("Overrided legacy!");\',\n self.production_folder.readFile(\'default.js\')\n )\n+\n+ def test_import(self):\n+ # If IBundleRegistry is in registry.xml, the combine-bundles import step\n+ # will call combine_bundles.\n+ from Products.CMFPlone.resources.exportimport.bundles import combine\n+ # from Products.CMFPlone.resources.browser.combine import get_override_directory\n+ # from Products.CMFPlone.resources.browser.combine import PRODUCTION_RESOURCE_DIRECTORY\n+\n+ # Prepare some registry xml files with or without the key IBundleRegistry.\n+ xml_with = \'with IBundleRegistry\'\n+ xml_without = \'without bundle registry\'\n+ xml_without2 = \'without bundle registry\'\n+ context = DummyImportContext(self.portal, purge=False)\n+\n+ def get_timestamp():\n+ # If combine_bundles is run, a timestamp is updated.\n+ return self.production_folder.readFile(\'timestamp.txt\')\n+\n+ ts1 = get_timestamp()\n+ self.assertTrue(ts1)\n+\n+ # call the import step on a file without bundles\n+ context._files = {\'registry.xml\': xml_without}\n+ combine(context)\n+ ts2 = get_timestamp()\n+ self.assertEqual(ts1, ts2)\n+\n+ # call the import step on a file with bundles\n+ context._files = {\'registry.xml\': xml_with}\n+ combine(context)\n+ ts3 = get_timestamp()\n+ self.assertLess(ts2, ts3)\n+\n+ # call the import step on a file without bundles\n+ context._files = {\'registry.xml\': xml_without2}\n+ combine(context)\n+ ts4 = get_timestamp()\n+ self.assertEqual(ts3, ts4)\n+\n+ # Since Plone 5.1 the registry xml can also be a directory.\n+ # Set one file with bundles.\n+ context._files = {\n+ \'registry.xml\': xml_without,\n+ \'registry/foo2.xml\': xml_with,\n+ \'registry/foo3.xml\': xml_without2,\n+ }\n+ context._directories = {\n+ \'registry\': [\n+ \'foo2.xml\',\n+ \'foo3.xml\',\n+ ]\n+ }\n+ combine(context)\n+ ts10 = get_timestamp()\n+ self.assertLess(ts4, ts10)\n+\n+ # The registry.xml file itself may be missing.\n+ context._files = {\n+ \'registry/foo2.xml\': xml_with,\n+ \'registry/foo3.xml\': xml_without2,\n+ }\n+ combine(context)\n+ ts11 = get_timestamp()\n+ self.assertLess(ts10, ts11)\n+\n+ # Now without any bundle info.\n+ context._files = {\n+ \'registry/foo2.xml\': xml_without,\n+ \'registry/foo3.xml\': xml_without2,\n+ }\n+ combine(context)\n+ ts12 = get_timestamp()\n+ self.assertEqual(ts11, ts12)\n' +b'diff --git a/CHANGES.rst b/CHANGES.rst\nindex a2d6039e..45c9b7e6 100644\n--- a/CHANGES.rst\n+++ b/CHANGES.rst\n@@ -13,6 +13,9 @@ New features:\n - Add upgrade steps for Datatbles on Plone 5.1.4\n [frapell]\n \n+- Add upgrade step removing the jquery-highlightsearchterms resource\n+ and the plone_ecmascript skin layer, on Plone 5.2 and 5.1.4\n+\n Bug fixes:\n \n - *add item here*\ndiff --git a/plone/app/upgrade/v51/configure.zcml b/plone/app/upgrade/v51/configure.zcml\nindex a56c241f..113678a9 100644\n--- a/plone/app/upgrade/v51/configure.zcml\n+++ b/plone/app/upgrade/v51/configure.zcml\n@@ -265,7 +265,7 @@ Add image scaling options to image handling control panel.\n \n \n \ndiff --git a/plone/app/upgrade/v51/final.py b/plone/app/upgrade/v51/final.py\nindex c6e9a498..8960caea 100644\n--- a/plone/app/upgrade/v51/final.py\n+++ b/plone/app/upgrade/v51/final.py\n@@ -1,6 +1,9 @@\n # -*- coding: utf-8 -*-\n+from plone.app.upgrade.utils import cleanUpSkinsTool\n+from plone.registry.interfaces import IRegistry\n from Products.CMFCore.utils import getToolByName\n from zExceptions import BadRequest\n+from zope.component import getUtility\n \n import logging\n \n@@ -38,3 +41,14 @@ def fix_i18n_domain(context):\n \'Action object/%s does not have an i18n_domain property\',\n action_id,\n )\n+\n+\n+def remove_highlightsearchterms(context):\n+ portal = getToolByName(context, \'portal_url\').getPortalObject()\n+ cleanUpSkinsTool(portal)\n+\n+ registry = getUtility(IRegistry)\n+ record = \'plone.bundles/plone-legacy.resources\'\n+ resources = registry.records[record]\n+ if u\'jquery-highlightsearchterms\' in resources.value:\n+ resources.value.remove(u\'jquery-highlightsearchterms\')\ndiff --git a/plone/app/upgrade/v51/profiles/to_514/registry.xml b/plone/app/upgrade/v51/profiles/to_514/registry.xml\nindex 83ad3c05..ef3704aa 100644\n--- a/plone/app/upgrade/v51/profiles/to_514/registry.xml\n+++ b/plone/app/upgrade/v51/profiles/to_514/registry.xml\n@@ -105,18 +105,29 @@\n ++plone++static/components/datatables.net-select/js/dataTables.select.min.js\n \n \n+ \n+ \n+\n \n \n- 2018-07-10 00:00:00\n+ 2018-09-06 00:00:00\n \n \n- 2018-07-10 00:00:00\n+ 2018-09-06 00:00:00\n+ \n+\n+ \n+ \n+ \n \n \n \ndiff --git a/plone/app/upgrade/v51/profiles/to_514/skins.xml b/plone/app/upgrade/v51/profiles/to_514/skins.xml\nnew file mode 100644\nindex 00000000..3e7c38da\n--- /dev/null\n+++ b/plone/app/upgrade/v51/profiles/to_514/skins.xml\n@@ -0,0 +1,11 @@\n+\n+\n+ \n+ \n+ \n+ \n+\ndiff --git a/plone/app/upgrade/v52/alphas.py b/plone/app/upgrade/v52/alphas.py\nindex 774a4b9d..972ee8a7 100644\n--- a/plone/app/upgrade/v52/alphas.py\n+++ b/plone/app/upgrade/v52/alphas.py\n@@ -1,7 +1,9 @@\n # -*- coding: utf-8 -*-\n from plone.app.upgrade.utils import cleanUpSkinsTool\n from plone.app.upgrade.utils import loadMigrationProfile\n+from plone.registry.interfaces import IRegistry\n from Products.CMFCore.utils import getToolByName\n+from zope.component import getUtility\n \n import logging\n \n@@ -13,3 +15,9 @@ def to52alpha1(context):\n loadMigrationProfile(context, \'profile-plone.app.upgrade.v52:to52alpha1\')\n portal = getToolByName(context, \'portal_url\').getPortalObject()\n cleanUpSkinsTool(portal)\n+\n+ registry = getUtility(IRegistry)\n+ record = \'plone.bundles/plone-legacy.resources\'\n+ resources = registry.records[record]\n+ if u\'jquery-highlightsearchterms\' in resources.value:\n+ resources.value.remove(u\'jquery-highlightsearchterms\')\ndiff --git a/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml b/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml\nnew file mode 100644\nindex 00000000..6582f962\n--- /dev/null\n+++ b/plone/app/upgrade/v52/profiles/to_alpha1/registry.xml\n@@ -0,0 +1,16 @@\n+\n+\n+\n+\n+ \n+ \n+\n+ \n+ \n+ \n+ \n+\n+\ndiff --git a/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml b/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml\nindex c0d3ddf6..12509b31 100644\n--- a/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml\n+++ b/plone/app/upgrade/v52/profiles/to_alpha1/skins.xml\n@@ -8,4 +8,12 @@\n \n \n \n+ \n+ \n+ \n+ \n \n'