diff mbox

[v3,6/6] Add .travis.yml file

Message ID 1470716861-6486-7-git-send-email-dja@axtens.net
State Accepted
Headers show

Commit Message

Daniel Axtens Aug. 9, 2016, 4:27 a.m. UTC
This automatically runs the tests (except the browser ones) via tox.
Only the following tests are run: py{27,35} and django {1.8,1.9}.

Tested on my github account. This will require some setup on the GitHub
end: Travis will need to be turned on for the project, and ideally a
badge added to the readme so we can see the build status.

Signed-off-by: Daniel Axtens <dja@axtens.net>
---
 .travis.yml | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)
 create mode 100644 .travis.yml

Comments

Stephen Finucane Aug. 13, 2016, 11:32 p.m. UTC | #1
On 09 Aug 14:27, Daniel Axtens wrote:
> This automatically runs the tests (except the browser ones) via tox.
> Only the following tests are run: py{27,35} and django {1.8,1.9}.
> 
> Tested on my github account. This will require some setup on the GitHub
> end: Travis will need to be turned on for the project, and ideally a
> badge added to the readme so we can see the build status.
> 
> Signed-off-by: Daniel Axtens <dja@axtens.net>

Looks good. I'll set up the required accounts first, then look at
merging this.

Reviewed-by: Stephen Finucane <stephenfinucane@hotmail.com>
diff mbox

Patch

diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 000000000000..49d3fc7b776d
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,25 @@ 
+language: python
+python: 3.5
+
+services:
+  - mysql
+
+env:
+  global:
+    - PW_TEST_DB_USER=travis
+    - PW_TEST_DB_PASS=""
+    - PW_SKIP_BROWSER_TESTS=yes
+  matrix:
+    - TOX_ENV=py27-django18
+    - TOX_ENV=py27-django19
+    - TOX_ENV=py35-django18
+    - TOX_ENV=py35-django19
+
+before_script:
+ - mysql -e 'create database patchwork character set utf8;'
+
+install:
+ - pip install tox
+
+script:
+ - tox -e $TOX_ENV