UNPKG

lux-framework

Version:

Build scalable, Node.js-powered REST APIs with almost no code.

78 lines (74 loc) 1.77 kB
machine: node: version: 6 environment: NODE_ENV: test DROP_DATABASE: DROP DATABASE IF EXISTS lux_test; CREATE_DATABASE: CREATE DATABASE lux_test; DATABASE_USERNAME: ubuntu database: override: - psql -c "$DROP_DATABASE" -U postgres - psql -c "$CREATE_DATABASE" -U postgres - mysql -e "$DROP_DATABASE" - mysql -e "$CREATE_DATABASE" dependencies: pre: - | cd ../ if [ -d watchman ]; then cd watchman sudo make install else git clone https://github.com/facebook/watchman.git cd watchman git checkout v4.7.0 ./autogen.sh ./configure make sudo make install fi cd ../lux override: - npm install - npm link post: - | cd test/test-app npm install cd ../../ cache_directories: - /home/ubuntu/watchman compile: pre: - npm run clean override: - npm run build test: pre: - case $CIRCLE_NODE_INDEX in 0) export DATABASE_DRIVER="pg" ;; 1) export DATABASE_DRIVER="mysql2" ;; 2) export DATABASE_DRIVER="sqlite3" ;; esac: parallel: true override: - npm run flow: parallel: true - npm run lint: parallel: true - npm test -- -R mocha-junit-reporter: parallel: true environment: MOCHA_FILE: $CIRCLE_TEST_REPORTS/junit/test-results.xml post: - npm run codecov: parallel: true notify: webhooks: - url: https://webhooks.gitter.im/e/6d49c9b19c888dba70b8 deployment: release: tag: /^(?:v\d.\d.\d)$/ commands: - npm run clean - npm run build - rm -rf ~/.npmrc && touch ~/.npmrc - echo //registry.npmjs.org/:_authToken=$NPM_AUTH_TOKEN >> ~/.npmrc - npm publish