From d4fc66de277392e2e4800f0a15ced3d7dd061578 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sta=C5=9B=20Ma=C5=82olepszy?= Date: Thu, 8 Mar 2018 12:50:02 +0100 Subject: [PATCH] Test Node 6 on Travis By default, make test requires babel-polyfill and all tests run fine even on older versions of Node. For fluent-syntax, howeever, we want to also run tests without the polyfill in order to make sure that fluent-syntax is actually runnable on Node 6. See #164. --- .travis.yml | 5 ++++- fluent-syntax/makefile | 4 ++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 5be44d6b6..0a1b8ea23 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,10 @@ sudo: false language: node_js -script: make deps && make dist +script: + - make deps && make dist + - [[ $(node --version) = v6.* ]] && make -C fluent-syntax test-without-babel-polyfill node_js: + - "6" - "8" cache: directories: node_modules diff --git a/fluent-syntax/makefile b/fluent-syntax/makefile index deaa0950e..4c356fdaa 100644 --- a/fluent-syntax/makefile +++ b/fluent-syntax/makefile @@ -23,6 +23,10 @@ compat.js: $(SOURCES) --output.file $@ @echo -e " $(OK) $@ built" +.PHONY: test-without-babel-polyfill +test-without-babel-polyfill: + @mocha --recursive --ui tdd --require babel-register test/ + clean: @rm -f $(PACKAGE).js compat.js @echo -e " $(OK) clean"