From 3a4dc74765f232f3b642b7622fe97daead3b995b Mon Sep 17 00:00:00 2001 From: Sean Corfield Date: Wed, 27 Jun 2018 11:09:23 -0700 Subject: [PATCH] Add multi-version (1.7, 1.8, 1.9, 1.10) Make Travis run all of those. Also remove O/S update for libstdc++6 to see if Lumo version pinning is sufficient. --- .travis.yml | 6 +----- CHANGES.md | 1 + project.clj | 15 +++++++++++---- run-tests.sh | 8 +++++++- 4 files changed, 20 insertions(+), 10 deletions(-) diff --git a/.travis.yml b/.travis.yml index e020c88..cd30eaa 100644 --- a/.travis.yml +++ b/.travis.yml @@ -9,14 +9,10 @@ cache: - $TRAVIS_BUILD_DIR/node_modules before_install: - - sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test - - sudo apt-get -qq update - - sudo apt-get install -y libstdc++6 - - strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX - sudo apt-get install -y leiningen - npm install lumo-cljs@1.9.0-alpha -g install: - jdk_switcher use openjdk8 -script: lein do check, eastwood, test, tach lumo, test-readme +script: lein do check, eastwood, test-all, tach lumo, test-readme diff --git a/CHANGES.md b/CHANGES.md index 8e244e7..c3bb466 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -3,6 +3,7 @@ * Add examples of table/column aliases to the README. Fix #215. (@seancorfield) * Refactor parameterizer to use multimethods. PR #214. (@xlevus) * Add examples of `raw` and `inline` to the README. Fix #213. (@seancorfield) +* Add multi-version testing for Clojure 1.7, 1.8, 1.9, 1.10 (master) (@seancorfield) * Bring all dependencies up-to-date. (@seancorfield) * Add `run-tests.sh` to make it easier to run the same tests manually that run on TravisCI. (@seancorfield) * Add `deps.edn` to support `clj`/`tools.deps.alpha`. (@seancorfield) diff --git a/project.clj b/project.clj index b0db4d6..597e4a0 100644 --- a/project.clj +++ b/project.clj @@ -5,9 +5,12 @@ :url "https://github.com/jkk/honeysql" :scm {:name "git" :url "https://github.com/jkk/honeysql"} - :dependencies [[org.clojure/clojure "1.8.0"] + :dependencies [[org.clojure/clojure "1.9.0"] [net.cgrand/macrovich "0.2.1"]] - :aliases {"test-readme" ["with-profile" "midje" "midje"]} + :aliases {"test-readme" ["with-profile" "midje" "midje"] + "test-all" ["with-profile" + "default:1.7,default:1.8,default:1.9,default:master" + "test"]} :cljsbuild {:builds {:release {:source-paths ["src"] :compiler {:output-to "dist/honeysql.js" :optimizations :advanced @@ -31,8 +34,12 @@ [honeysql.helpers :refer :all :as helpers] [honeysql.format :as fmt] [honeysql.helpers :refer [defhelper]]"}} - :dev {:dependencies [[org.clojure/clojure "1.8.0"] - [org.clojure/clojurescript "1.9.521"] + :master {:repositories [["snapshots" "https://oss.sonatype.org/content/repositories/snapshots/"]] + :dependencies [[org.clojure/clojure "1.10.0-master-SNAPSHOT"]]} + :1.9 {:dependencies [[org.clojure/clojure "1.9.0"]]} + :1.8 {:dependencies [[org.clojure/clojure "1.8.0"]]} + :1.7 {:dependencies [[org.clojure/clojure "1.7.0"]]} + :dev {:dependencies [[org.clojure/clojurescript "1.9.521"] [cljsbuild "1.1.7"]] :plugins [[lein-cljsbuild "1.1.7"] [jonase/eastwood "0.2.6"] diff --git a/run-tests.sh b/run-tests.sh index b742f0b..5e51e80 100755 --- a/run-tests.sh +++ b/run-tests.sh @@ -4,4 +4,10 @@ # See .travis.yml for details of the test environment. # rm -rf test/readme.clj -lein do clean, check, eastwood, test, tach lumo, test-readme +if test "$1" = "all" +then + clj_test="test-all" +else + clj_test="test" +fi +lein do clean, check, eastwood, $clj_test, tach lumo, test-readme