This is an automated email from the ASF dual-hosted git repository.
ccwilliams pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git
The following commit(s) were added to refs/heads/master by this push:
new 50c701c [ci] Update ci config to reduce javascript test time and some
of cypress. (#6016)
50c701c is described below
commit 50c701c0e86de08385e97d34b2dcd41e6c5ff5cd
Author: Krist Wongsuphasawat <[email protected]>
AuthorDate: Thu Oct 4 14:54:44 2018 -0700
[ci] Update ci config to reduce javascript test time and some of cypress.
(#6016)
* try travis config
* try more complex config
* fix config
* add cache and stages
* separate cache
* swap order
* fix redis
* remove env
* add cypress
* adjust caching
* reduce cache
* change order of execution
* change order again
* change node version
* install yarn via curl
* update cypress command
* update cypress command
* adjust cache and node version
* do not install yarn
* add npm cache
* remove export
* remove commented code
* change order of jobs
* fix indent
---
.travis.yml | 94 ++++++++++++++++++++++++++--------------
superset/assets/cypress_build.sh | 5 +--
2 files changed, 63 insertions(+), 36 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index a02d009..180db34 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,44 +1,72 @@
-language: python
-python:
- - 2.7
- - 3.6
-services:
- - mysql
- - postgres
- - redis-server
cache:
- - pip
-matrix:
+ pip: true
+jobs:
include:
- - python: 2.7
+ - language: python
+ python: 3.6
+ env: TOXENV=cypress
+ cache:
+ pip: true
+ yarn: true
+ directories:
+ - ~/.npm
+ - ~/.cache
+ services:
+ - redis-server
+ before_install:
+ - nvm install 8.9
+ - language: python
+ python: 2.7
env: TOXENV=flake8
- - python: 2.7
- env: TOXENV=py27-mysql
- - python: 2.7
+ - language: python
+ python: 2.7
env: TOXENV=py27-sqlite
- - python: 2.7
+ services:
+ - redis-server
+ - language: python
+ python: 2.7
+ env: TOXENV=py27-mysql
+ services:
+ - mysql
+ - redis-server
+ before_script:
+ - mysql -u root -e "DROP DATABASE IF EXISTS superset; CREATE DATABASE
superset DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci"
+ - mysql -u root -e "CREATE USER 'mysqluser'@'localhost' IDENTIFIED BY
'mysqluserpassword';"
+ - mysql -u root -e "GRANT ALL ON superset.* TO
'mysqluser'@'localhost';"
+ - language: python
+ python: 2.7
env: TOXENV=pylint
- - python: 3.6
+ - language: node_js
+ node_js: 8.9
+ cache:
+ yarn: true
+ before_install:
+ - cd superset/assets
+ install:
+ - yarn install --frozen-lockfile
+ script:
+ - npm run lint
+ - npm run cover
+ - language: python
+ python: 3.6
env: TOXENV=flake8
- - python: 3.6
- env: TOXENV=javascript
- - python: 3.6
- env: TOXENV=py36-postgres
- - python: 3.6
+ - language: python
+ python: 3.6
env: TOXENV=py36-sqlite
- - python: 3.6
+ services:
+ - redis-server
+ - language: python
+ python: 3.6
+ env: TOXENV=py36-postgres
+ services:
+ - postgres
+ - redis-server
+ before_script:
+ - psql -U postgres -c "CREATE DATABASE superset;"
+ - psql -U postgres -c "CREATE USER postgresuser WITH PASSWORD
'pguserpassword';"
+ - language: python
+ python: 3.6
env: TOXENV=pylint
- - python: 3.6
- env: TOXENV=cypress
- exclude:
- - python: 2.7
- - python: 3.6
-before_script:
- - mysql -u root -e "DROP DATABASE IF EXISTS superset; CREATE DATABASE
superset DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci"
- - mysql -u root -e "CREATE USER 'mysqluser'@'localhost' IDENTIFIED BY
'mysqluserpassword';"
- - mysql -u root -e "GRANT ALL ON superset.* TO 'mysqluser'@'localhost';"
- - psql -U postgres -c "CREATE DATABASE superset;"
- - psql -U postgres -c "CREATE USER postgresuser WITH PASSWORD
'pguserpassword';"
install:
- pip install --upgrade pip
- pip install codecov tox
diff --git a/superset/assets/cypress_build.sh b/superset/assets/cypress_build.sh
index 950e01a..26b0a08 100755
--- a/superset/assets/cypress_build.sh
+++ b/superset/assets/cypress_build.sh
@@ -9,8 +9,7 @@ superset/bin/superset runserver &
cd "$(dirname "$0")"
-npm install -g yarn
-yarn
+yarn install --frozen-lockfile
npm run build
-npm run cypress run --record
+npm run cypress run
kill %1