[MediaWiki-commits] [Gerrit] integration/config[master]: Inject skin/ext dependencies

2016-12-13 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/326469 )

Change subject: Inject skin/ext dependencies
..


Inject skin/ext dependencies

Up until previous commit, we only supported injecting extensions and
only on extensions jobs.  We now support skins, apply the mecanism on a
couple repositories that have been identified to need that:

CustomPage extension requires the skin CustomPage.
BlueSpiceSkin skin requires the extension BlueSpiceFoundation

Add tests to exercise the feature.

Bug: T151593
Change-Id: Idc1d5774fe79d4f3542529bd18e09f06fcf6e3d0
---
M tests/test_zuul_mw_dependencies.py
M zuul/parameter_functions.py
2 files changed, 28 insertions(+), 0 deletions(-)

Approvals:
  Paladox: Looks good to me, but someone else must approve
  Hashar: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/tests/test_zuul_mw_dependencies.py 
b/tests/test_zuul_mw_dependencies.py
index bc30074..de6098a 100644
--- a/tests/test_zuul_mw_dependencies.py
+++ b/tests/test_zuul_mw_dependencies.py
@@ -128,3 +128,25 @@
 get_dependencies('skins/Child', mapping),
 set(['skin/Common'])
 )
+
+def test_inject_skin_on_an_extension(self):
+deps = self.fetch_dependencies(
+job_name='mwext-testextension-hhvm',
+project='mediawiki/extensions/CustomPage')
+self.assertDictContainsSubset(
+{
+'EXT_NAME': 'CustomPage',
+'SKIN_DEPENDENCIES': 'mediawiki/skins/CustomPage',
+},
+deps)
+
+def test_inject_extension_on_a_skin(self):
+deps = self.fetch_dependencies(
+job_name='mw-testskin',
+project='mediawiki/skins/BlueSpiceSkin')
+self.assertDictContainsSubset(
+{
+'SKIN_NAME': 'BlueSpiceSkin',
+'EXT_DEPENDENCIES': 'mediawiki/extensions/BlueSpiceFoundation',
+},
+deps)
diff --git a/zuul/parameter_functions.py b/zuul/parameter_functions.py
index 7e5fbb9..cf1cb13 100644
--- a/zuul/parameter_functions.py
+++ b/zuul/parameter_functions.py
@@ -101,6 +101,11 @@
 # 'skins/'.  The has is used by the set_mw_dependencies() parameter function
 # below.
 dependencies = {
+# Skins are listed first to highlight the skin dependencies
+'skins/BlueSpiceSkin': ['BlueSpiceFoundation'],
+
+# Extensions
+# One can add a skin by using: 'skin/X'
 'AbuseFilter': ['AntiSpoof'],
 'ApiFeatureUsage': ['Elastica'],
 'Arrays': ['Loops', 'ParserFunctions', 'Variables'],
@@ -116,6 +121,7 @@
 'ContentTranslation': ['Echo', 'EventLogging', 'GuidedTour',
'UniversalLanguageSelector', 'Wikidata'],
 'CookieWarning': ['MobileFrontend'],
+'CustomPage': ['skins/CustomPage'],
 'Disambiguator': ['VisualEditor'],
 'DonationInterface': ['ContributionTracking'],
 'EducationProgram': ['cldr', 'WikiEditor'],

-- 
To view, visit https://gerrit.wikimedia.org/r/326469
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Idc1d5774fe79d4f3542529bd18e09f06fcf6e3d0
Gerrit-PatchSet: 2
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Hashar 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] integration/config[master]: Inject skin/ext dependencies

2016-12-12 Thread Hashar (Code Review)
Hashar has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/326469 )

Change subject: Inject skin/ext dependencies
..

Inject skin/ext dependencies

Up until previous commit, we only supported injecting extensions and
only on extensions jobs.  We now support skins, apply the mecanism on a
couple repositories that have been identified to need that:

CustomPage extension requires the skin CustomPage.
BlueSpiceSkin skin requires the extension BlueSpiceFoundation

Add tests to exercise the feature.

Bug: T151593
Change-Id: Idc1d5774fe79d4f3542529bd18e09f06fcf6e3d0
---
M tests/test_zuul_mw_dependencies.py
M zuul/parameter_functions.py
2 files changed, 28 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/69/326469/1

diff --git a/tests/test_zuul_mw_dependencies.py 
b/tests/test_zuul_mw_dependencies.py
index bc30074..de6098a 100644
--- a/tests/test_zuul_mw_dependencies.py
+++ b/tests/test_zuul_mw_dependencies.py
@@ -128,3 +128,25 @@
 get_dependencies('skins/Child', mapping),
 set(['skin/Common'])
 )
+
+def test_inject_skin_on_an_extension(self):
+deps = self.fetch_dependencies(
+job_name='mwext-testextension-hhvm',
+project='mediawiki/extensions/CustomPage')
+self.assertDictContainsSubset(
+{
+'EXT_NAME': 'CustomPage',
+'SKIN_DEPENDENCIES': 'mediawiki/skins/CustomPage',
+},
+deps)
+
+def test_inject_extension_on_a_skin(self):
+deps = self.fetch_dependencies(
+job_name='mw-testskin',
+project='mediawiki/skins/BlueSpiceSkin')
+self.assertDictContainsSubset(
+{
+'SKIN_NAME': 'BlueSpiceSkin',
+'EXT_DEPENDENCIES': 'mediawiki/extensions/BlueSpiceFoundation',
+},
+deps)
diff --git a/zuul/parameter_functions.py b/zuul/parameter_functions.py
index d2cf4e7..a54ee67 100644
--- a/zuul/parameter_functions.py
+++ b/zuul/parameter_functions.py
@@ -101,6 +101,11 @@
 # 'skins/'.  The has is used by the set_mw_dependencies() parameter function
 # below.
 dependencies = {
+# Skins are listed first to highlight the skin dependencies
+'skins/BlueSpiceSkin': ['BlueSpiceFoundation'],
+
+# Extensions
+# One can add a skin by using: 'skin/X'
 'AbuseFilter': ['AntiSpoof'],
 'ApiFeatureUsage': ['Elastica'],
 'Arrays': ['Loops', 'ParserFunctions', 'Variables'],
@@ -116,6 +121,7 @@
 'ContentTranslation': ['Echo', 'EventLogging', 'GuidedTour',
'UniversalLanguageSelector', 'Wikidata'],
 'CookieWarning': ['MobileFrontend'],
+'CustomPage': ['skins/CustomPage'],
 'Disambiguator': ['VisualEditor'],
 'DonationInterface': ['ContributionTracking'],
 'EducationProgram': ['cldr', 'WikiEditor'],

-- 
To view, visit https://gerrit.wikimedia.org/r/326469
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idc1d5774fe79d4f3542529bd18e09f06fcf6e3d0
Gerrit-PatchSet: 1
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Hashar 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits