Skip to content

Commit

Permalink
.travis.yml: Move moban to separate stage
Browse files Browse the repository at this point in the history
Related to coala#282
  • Loading branch information
jayvdb committed Aug 4, 2018
1 parent 930a77c commit 7fef0b0
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 3 deletions.
13 changes: 13 additions & 0 deletions .ci/check_moban.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/bash

set -ex

: "${MOBAN_BRANCH:=master}"

if [ ! -d ../coala-mobans ]; then
git clone https://gitlab.com/coala/mobans \
--branch=${MOBAN_BRANCH} ../coala-mobans
fi

moban
git diff --exit-code
1 change: 1 addition & 0 deletions .moban.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,4 @@ targets:
- coala_quickstart/__init__.py: __init__.py.jj2
- .ci/appveyor.yml: ci/appveyor.yml.jj2
- .ci/run_with_env.cmd: run_with_env.cmd
- .ci/check_moban.sh: ci/check_moban.sh
23 changes: 20 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,32 @@ python:
- 3.5
- 3.6

stages:
- test
- moban

.disable_global: &disable_global
before_install: false
install: false
script: false

.check_moban: &check_moban
<<: *disable_global
python: 3.6
stage: moban
install: pip install moban
script: .ci/check_moban.sh

jobs:
include:
- *check_moban

cache:
pip: true

before_install:
- pip install setuptools -U
- pip install -r requirements.txt -r test-requirements.txt
- git clone https://gitlab.com/coala/mobans ../coala-mobans
- moban
- git diff --exit-code

script:
- pytest
Expand Down

0 comments on commit 7fef0b0

Please sign in to comment.