Krinkle has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/201938

Change subject: macro: Create npm-run-test and npm-run-doc
......................................................................

macro: Create npm-run-test and npm-run-doc

Change-Id: I743f0be69f0736bda09710a8ccb816aecdcf80fa
---
M jjb/macro.yaml
M jjb/mediawiki.yaml
M jjb/misc.yaml
3 files changed, 24 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/38/201938/1

diff --git a/jjb/macro.yaml b/jjb/macro.yaml
index 67834ef..d1f4572 100644
--- a/jjb/macro.yaml
+++ b/jjb/macro.yaml
@@ -118,6 +118,26 @@
         npm install
         npm test
 
+# The npm-run-* macros are intended to be used when multiple are used
+# together (e.g. 'doc' and later 'test'). If you simply need to run
+# npm-install and npm-run-test, use the plain 'npm' macro instead.
+#
+# MUST run npm-setup.sh before this (e.g. via npm-install macro)
+#
+# ALWAYS pair with 'global-teardown'
+- builder:
+    name: npm-run-test
+    builders:
+    - shell: |
+        . /srv/deployment/integration/slave-scripts/bin/npm-set-env.sh
+        npm test
+- builder:
+    name: npm-run-doc
+    builders:
+    - shell: |
+        . /srv/deployment/integration/slave-scripts/bin/npm-set-env.sh
+        npm run-script doc
+
 # Variant that can use a deploy repo for the dependencies.
 # See macro setup-npm-oid below.
 #
diff --git a/jjb/mediawiki.yaml b/jjb/mediawiki.yaml
index 5c6dd58..fc63e3d 100644
--- a/jjb/mediawiki.yaml
+++ b/jjb/mediawiki.yaml
@@ -64,7 +64,7 @@
     builders:
      - assert-env-doc_subpath
      - npm-install
-     - shell: npm run-script doc
+     - npm-run-doc
      - doc-publish:
         docsrc: 'docs/js'
         docdest: 'mediawiki-core/$DOC_SUBPATH/js'
diff --git a/jjb/misc.yaml b/jjb/misc.yaml
index e2d1144..bd0c5db 100644
--- a/jjb/misc.yaml
+++ b/jjb/misc.yaml
@@ -21,13 +21,11 @@
      - zuul
     builders:
      - npm-install
-     - shell: npm run-script doc
+     - npm-run-doc
      - doc-publish:
         docsrc: 'docs'
         docdest: 'oojs/$ZUUL_BRANCH'
-     - shell: |
-         . /srv/deployment/integration/slave-scripts/bin/npm-set-env.sh
-         npm test
+     - npm-run-test
      - cover-publish:
         src: 'coverage'
         dest: 'oojs'
@@ -43,7 +41,7 @@
      - zuul
     builders:
      - npm-install
-     - shell: npm run-script doc
+     - npm-run-doc
      - doc-publish:
         docsrc: 'docs'
         docdest: 'oojs-ui/$ZUUL_BRANCH'

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I743f0be69f0736bda09710a8ccb816aecdcf80fa
Gerrit-PatchSet: 1
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Krinkle <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to