blob: 598c503a984e597180d9c1dbd6f412c1a46add19 [file] [log] [blame]
Pratik Vyascc9bc952014-02-06 14:59:05 +05301language: python
Pratik Vyasf437e862013-12-24 12:17:59 +05302
3python:
4 - "2.7"
5
6services:
7 - mysql
8
9install:
Anand Doshi3be9e262014-03-25 18:39:35 +053010 - sudo apt-get purge -y mysql-common
Pratik Vyas2a47eeb2015-01-01 15:48:04 +053011 - wget https://raw.githubusercontent.com/frappe/bench/master/install_scripts/setup_frappe.sh
12 - sudo bash setup_frappe.sh --skip-setup-bench --mysql-root-password travis
13 - sudo service redis-server start
14 - rm $TRAVIS_BUILD_DIR/.git/shallow
Pratik Vyasf2eed442015-03-23 16:23:28 +053015 - cd ~/ && bench init frappe-bench --frappe-path https://github.com/frappe/frappe.git --frappe-branch develop
Pratik Vyas2a47eeb2015-01-01 15:48:04 +053016 - cp -r $TRAVIS_BUILD_DIR/test_sites/test_site ~/frappe-bench/sites/
Pratik Vyas86680812014-10-12 19:35:46 +053017
Pratik Vyas2a47eeb2015-01-01 15:48:04 +053018script:
19 - cd ~/frappe-bench
20 - bench get-app erpnext $TRAVIS_BUILD_DIR
Pratik Vyas52d36972015-03-31 13:11:32 +053021 - bench use test_site
Pratik Vyas4ce79772015-03-31 13:16:29 +053022 - bench reinstall
23 - bench build-website
24 - bench --verbose run-tests
Pratik Vyasf437e862013-12-24 12:17:59 +053025
Anand Doshic5dbf0f2014-06-18 13:35:37 +053026before_script:
27 - mysql -e 'create database test_frappe'
Pratik Vyas2a47eeb2015-01-01 15:48:04 +053028 - echo "USE mysql;\nCREATE USER 'test_frappe'@'localhost' IDENTIFIED BY 'test_frappe';\nFLUSH PRIVILEGES;\n" | mysql -u root -ptravis
29 - echo "USE mysql;\nGRANT ALL PRIVILEGES ON \`test_frappe\`.* TO 'test_frappe'@'localhost';\n" | mysql -u root -ptravis
Anand Doshic5dbf0f2014-06-18 13:35:37 +053030