diff --git a/jobs/templates/swh-tox.yaml b/jobs/templates/swh-tox.yaml index 1eaef6e..4aecc8a 100644 --- a/jobs/templates/swh-tox.yaml +++ b/jobs/templates/swh-tox.yaml @@ -1,46 +1,47 @@ - job-template: name: '{name}/tox' node: swh-tox auth-token: ph4br1cat0r parameters: - string: name: REPO description: PHID of the Diffusion repository - string: name: PHID description: PHID of the Target object - - string: - name: COMMIT - description: commit ID to test, if any - string: name: DIFF_ID description: ID of the Diff patch to apply, if any scm: - git: url: https://forge.softwareheritage.org/source/{display-name}.git wrappers: - - phabricator-differential + - phabricator-differential: + apply-to-master: true builders: - shell: | echo "Run tox for:" echo " REPO=$REPO" echo " PHID=$PHID" - echo " COMMIT=$COMMIT" echo " DIFF_ID=$DIFF_ID" - shell: | - if [ -n "$COMMIT" ]; then - echo "Checkout commit $COMMIT" - git checkout $COMMIT + if (tox -a | grep -q -e '^flake8-phab$' ); then + python3 -m tox -e flake8-phab + else + python3 -m tox -e flake8 fi - shell: python3 -m tox --result-json tox-results.json publishers: - phabricator: uberalls-enabled: false comment-on-success: true comment-with-console-link-on-failure: true + process-lint: true + lint-file: .phabricator-lint + lint-file-size: 1000000 - archive: - artifacts: "*.json,.coverage" + artifacts: "*.json,.coverage*,.phabricator*"