Skip to content

Commit

Permalink
added travis-ci configuration and codeclimate status
Browse files Browse the repository at this point in the history
  • Loading branch information
nodecarter committed Sep 28, 2013
1 parent c160de0 commit d059e2a
Show file tree
Hide file tree
Showing 4 changed files with 66 additions and 0 deletions.
52 changes: 52 additions & 0 deletions .travis.yml
@@ -0,0 +1,52 @@
language: ruby

services:
- mysql
- postgresql

rvm:
- 1.9.3
- 2.0.0

env:
- REDMINE_VER=2.1.6 DB=mysql
- REDMINE_VER=2.2.4 DB=mysql
- REDMINE_VER=2.3.3 DB=mysql
- REDMINE_VER=2.1.6 DB=postgresql
- REDMINE_VER=2.2.4 DB=postgresql
- REDMINE_VER=2.3.3 DB=postgresql

branches:
only:
- master

matrix:
exclude:
- rvm: 2.0.0
env: REDMINE_VER=2.1.6 DB=mysql
- rvm: 2.0.0
env: REDMINE_VER=2.2.4 DB=mysql
- rvm: 2.0.0
env: REDMINE_VER=2.1.6 DB=postgresql
- rvm: 2.0.0
env: REDMINE_VER=2.2.4 DB=postgresql

before_install:
- export PLUGIN_NAME=redmine_lightbox
- export REDMINE_PATH=$HOME/redmine
- git clone --depth=1 --branch=$REDMINE_VER https://github.com/redmine/redmine.git $REDMINE_PATH
- ln -s $TRAVIS_BUILD_DIR $REDMINE_PATH/plugins/$PLUGIN_NAME
- cp config/database-$DB-travis.yml $REDMINE_PATH/config/database.yml
- cd $REDMINE_PATH

install:
- bundle install

before_script:
- rake db:create
- rake db:migrate
- rake redmine:plugins:migrate

script:
- rake redmine:plugins:test NAME=$PLUGIN_NAME

3 changes: 3 additions & 0 deletions README.markdown
@@ -1,6 +1,9 @@
Redmine Lightbox plugin
=======================

[![Build Status](https://travis-ci.org/Undev/redmine_lightbox.png?branch=master)](https://travis-ci.org/Undev/redmine_lightbox)
[![Code Climate](https://codeclimate.com/github/Undev/redmine_lightbox.png)](https://codeclimate.com/github/Undev/redmine_lightbox)

This plugin lets you preview the image, pdf and swf attachments in a lightbox.

Screenshots
Expand Down
6 changes: 6 additions & 0 deletions config/database-mysql-travis.yml
@@ -0,0 +1,6 @@
# http://about.travis-ci.org/docs/user/database-setup/#MySQL
test:
adapter: mysql2
database: redmine
username: travis
encoding: utf8
5 changes: 5 additions & 0 deletions config/database-postgresql-travis.yml
@@ -0,0 +1,5 @@
# http://about.travis-ci.org/docs/user/database-setup/#PostgreSQL
test:
adapter: postgresql
database: redmine
username: postgres

0 comments on commit d059e2a

Please sign in to comment.