Skip to content

Commit

Permalink
Add xlsx-validator to travis build matrix
Browse files Browse the repository at this point in the history
  • Loading branch information
Hörður Freyr Yngvason committed Apr 1, 2017
1 parent 977c09d commit 18263b4
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
.git
.bundle
vendor
ci/Dockerfile
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ unzip
coverage
.yardoc
coverage.data
vendor
*.gem
*.xlsx
example.csv
Expand All @@ -18,4 +19,4 @@ examples/sprk2012
.~lock*
*.qcachegrind
*.iml
.idea
.idea
3 changes: 3 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ matrix:
- rvm: ruby-head
- rvm: jruby-head
env: JRUBY_OPTS="-Xcli.debug=true --debug"
- services: docker
before_install: docker build . -f ci/Dockerfile -t axlsx
script: docker run axlsx ci/validate-xlsx-files.sh
allow_failures:
- rvm: rbx-3
- rvm: ruby-head
Expand Down
13 changes: 13 additions & 0 deletions ci/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# vim: set ft=Dockerfile

FROM vindvaki/xlsx-validator

RUN apt-get install -y build-essential ruby ruby-dev libxslt-dev libxml2-dev zlib1g-dev
RUN gem install bundler
ADD Gemfile Gemfile.lock axlsx.gemspec /app/axlsx/
WORKDIR /app/axlsx/
ADD lib/axlsx/version.rb lib/axlsx/version.rb
RUN bundle install
ADD . .

ADD ci/validate-xlsx-files.sh .
4 changes: 4 additions & 0 deletions ci/validate-xlsx-files.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env bash

bundle exec ruby examples/example.rb
xlsx-validator *.xlsx

0 comments on commit 18263b4

Please sign in to comment.