summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.travis.yml145
-rw-r--r--library/tcltest/tcltest.tcl4
-rw-r--r--tests/unixInit.test3
3 files changed, 149 insertions, 3 deletions
diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 0000000..64801ec
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,145 @@
+dist: trusty
+sudo: false
+language: c
+matrix:
+ include:
+ - os: linux
+ compiler: clang
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=unix
+ - os: linux
+ compiler: clang
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=unix
+ - CFGOPT=--disable-shared
+ - os: linux
+ compiler: gcc
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=unix
+ - os: linux
+ compiler: gcc
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=unix
+ - CFGOPT=--disable-shared
+ - os: linux
+ compiler: gcc
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-4.9
+ env:
+ - MATRIX_EVAL="CC=gcc-4.9"
+ - BUILD_DIR=unix
+ - os: linux
+ compiler: gcc
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-5
+ env:
+ - MATRIX_EVAL="CC=gcc-5"
+ - BUILD_DIR=unix
+ - os: linux
+ compiler: gcc
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-6
+ env:
+ - MATRIX_EVAL="CC=gcc-6"
+ - BUILD_DIR=unix
+ - os: linux
+ compiler: gcc
+ addons:
+ apt:
+ sources:
+ - ubuntu-toolchain-r-test
+ packages:
+ - g++-7
+ env:
+ - MATRIX_EVAL="CC=gcc-7"
+ - BUILD_DIR=unix
+ - os: osx
+ osx_image: xcode8
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=unix
+ - os: osx
+ osx_image: xcode8
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=macosx
+ - NO_DIRECT_CONFIGURE=1
+ - os: osx
+ osx_image: xcode9
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=macosx
+ - NO_DIRECT_CONFIGURE=1
+ - os: osx
+ osx_image: xcode10
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=macosx
+ - NO_DIRECT_CONFIGURE=1
+# Test with mingw-w64 (32 bit)
+ - os: linux
+ compiler: i686-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-i686
+ - gcc-mingw-w64-i686
+ - gcc-mingw-w64
+ - gcc-multilib
+ - wine
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=win
+ - CFGOPT=--host=i686-w64-mingw32
+ - NO_DIRECT_TEST=1
+
+# Test with mingw-w64 (64 bit)
+ - os: linux
+ compiler: x86_64-w64-mingw32-gcc
+ addons:
+ apt:
+ packages:
+ - gcc-mingw-w64-base
+ - binutils-mingw-w64-x86-64
+ - gcc-mingw-w64-x86-64
+ - gcc-mingw-w64
+ - wine
+ env:
+ - MATRIX_EVAL=""
+ - BUILD_DIR=win
+ - CFGOPT=--host=x86_64-w64-mingw32 --enable-64bit
+ - NO_DIRECT_TEST=1
+
+### C builds not currently supported on Windows instances
+# - os: windows
+# env:
+# - MATRIX_EVAL=""
+# - BUILD_DIR=win
+
+before_install:
+ - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then rvm get stable; fi
+ - eval "${MATRIX_EVAL}"
+ - export ERROR_ON_FAILURES=1
+ - cd ${BUILD_DIR}
+install:
+ - test -n "$NO_DIRECT_CONFIGURE" || ./configure ${CFGOPT}
+script:
+ - make
+ - test -n "$NO_DIRECT_TEST" || make test
diff --git a/library/tcltest/tcltest.tcl b/library/tcltest/tcltest.tcl
index 410aa24..d67a900 100644
--- a/library/tcltest/tcltest.tcl
+++ b/library/tcltest/tcltest.tcl
@@ -2752,6 +2752,7 @@ proc tcltest::runAllTests { {shell ""} } {
variable numTests
variable failFiles
variable DefaultValue
+ set failFilesAccum {}
FillFilesExisted
if {[llength [info level 0]] == 1} {
@@ -2841,6 +2842,7 @@ proc tcltest::runAllTests { {shell ""} } {
}
if {$Failed > 0} {
lappend failFiles $testFile
+ lappend failFilesAccum $testFile
}
} elseif {[regexp [join {
{^Number of tests skipped }
@@ -2887,7 +2889,7 @@ proc tcltest::runAllTests { {shell ""} } {
puts [outputChannel] ""
puts [outputChannel] [string repeat ~ 44]
}
- return [info exists testFileFailures]
+ return [expr {[info exists testFileFailures] || [llength $failFilesAccum]}]
}
#####################################################################
diff --git a/tests/unixInit.test b/tests/unixInit.test
index 0469ee8..74307dd 100644
--- a/tests/unixInit.test
+++ b/tests/unixInit.test
@@ -341,8 +341,7 @@ test unixInit-3.1 {TclpSetInitialEncodings} -constraints {
return $enc
} -cleanup {
unset -nocomplain env(LANG)
-} -match regexp -result [expr {
- ($tcl_platform(os) eq "Darwin") ? "^utf-8$" : "^iso8859-15?$"}]
+} -match regexp -result {^(iso8859-15?|utf-8)$}
test unixInit-3.2 {TclpSetInitialEncodings} -setup {
catch {set oldlc_all $env(LC_ALL)}
} -constraints {unix stdio} -body {