Skip to content

Commit 11686eb

Browse files
authored
Merge pull request #375 from sourceryinstitute/issue-342-developer-test-flag
Urgent bugfix: Fixes 342 developer test flag
2 parents 045737a + e293e5d commit 11686eb

File tree

2 files changed

+26
-12
lines changed

2 files changed

+26
-12
lines changed

.travis.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ env:
77
- MPICH_URL_HEAD="http://www.mpich.org/static/downloads/$MPICH_VER"
88
- MPICH_URL_TAIL="mpich-${MPICH_VER}.tar.gz"
99
- MPICH_DIR="$HOME/.local/usr/mpich"
10-
- MPICH_BOT_URL_HEAD="https://github.com/sourceryinstitute/opencoarrays/files/452136/"
11-
- MPICH_BOT_URL_TAIL="mpich-3.2_2.yosemite.bottle.1.tar.gz"
10+
- MPICH_BOT_URL_HEAD="https://github.com/sourceryinstitute/OpenCoarrays/files/976766/"
11+
- MPICH_BOT_URL_TAIL="mpich-3.2_3.yosemite.bottle.1.tar.gz"
1212
- FC=gfortran-6
1313
- CC=gcc-6
1414
- CXX=g++-6
@@ -18,15 +18,15 @@ matrix:
1818
- os: osx
1919
env:
2020
- BUILD_TYPE="CodeCoverage"
21-
OSX_PACKAGES="gcc cmake"
21+
OSX_PACKAGES="gcc@6 cmake"
2222
- os: osx
2323
env:
2424
- BUILD_TYPE="Release"
25-
OSX_PACKAGES="gcc cmake"
25+
OSX_PACKAGES="gcc@6 cmake"
2626
- os: osx
2727
env:
2828
- BUILD_TYPE="InstallScript"
29-
OSX_PACKAGES="gcc"
29+
OSX_PACKAGES="gcc@6"
3030
- &ubuntu
3131
os: linux
3232
sudo: false
@@ -119,8 +119,10 @@ install:
119119
if ! [[ "$(brew ls --versions mpich)" ]]; then
120120
brew install --force-bottle mpich
121121
fi
122-
mpif90 --version
123-
mpicc --version
122+
rm -rf /usr/local/opt/gcc || true
123+
ln -s /usr/local/opt/gcc@6 /usr/local/opt/gcc # hack to get dynamic linker to find gcc 6 stuff
124+
mpif90 --version || mpif90 -show
125+
mpicc --version || mpicc -show
124126
cmake --version
125127
elif [[ "X$BUILD_TYPE" = "XInstallScript" ]]; then # uninstall some stuff if present
126128
[[ "$(brew ls --versions cmake)" ]] && brew rm cmake || true

CMakeLists.txt

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,14 @@ set ( CMAKE_BUILD_TYPE "Release"
66
CACHE STRING "Select which configuration to build." )
77
set_property ( CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS ${CMAKE_CONFIGURATION_TYPES} )
88

9+
# Add option and check environment to determine if developer tests should be run
10+
if(ENV{OPENCOARRAYS_DEVELOPER})
11+
option(RUN_DEVELOPER_TESTS "Run tests intended only for developers" ON)
12+
else()
13+
option(RUN_DEVELOPER_TESTS "Run tests intended only for developers" OFF)
14+
endif()
15+
mark_as_advanced(RUN_DEVELOPER_TESTS)
16+
917
# Name project and specify source languages
1018
# Parse version from .VERSION file so that more info can be added and easier to get from scripts
1119
file( STRINGS ".VERSION" OpenCoarraysVersion
@@ -468,10 +476,12 @@ if(opencoarrays_aware_compiler)
468476
add_mpi_test(register_alloc_comp_1 2 ${tests_root}/unit/init_register/register_alloc_comp_1)
469477
add_mpi_test(register_alloc_comp_2 2 ${tests_root}/unit/init_register/register_alloc_comp_2)
470478
add_mpi_test(register_alloc_comp_3 2 ${tests_root}/unit/init_register/register_alloc_comp_3)
471-
add_mpi_test(async_comp_alloc 6 ${tests_root}/unit/init_register/async_comp_alloc)
472-
# Timeout async_comp_alloc test after 3 seconds to progess past the known failure
473-
set_property(TEST async_comp_alloc PROPERTY TIMEOUT_AFTER_MATCH 3 "known failure")
474-
set_property(TEST async_comp_alloc PROPERTY TIMEOUT 6) # in the event old CMake is being used
479+
if (RUN_DEVELOPER_TESTS)
480+
add_mpi_test(async_comp_alloc 6 ${tests_root}/unit/init_register/async_comp_alloc)
481+
# Timeout async_comp_alloc test after 3 seconds to progess past the known failure
482+
set_property(TEST async_comp_alloc PROPERTY TIMEOUT_AFTER_MATCH 3 "known failure")
483+
set_property(TEST async_comp_alloc PROPERTY TIMEOUT 6) # in the event old CMake is being used
484+
endif()
475485
endif()
476486
add_mpi_test(get_array 2 ${tests_root}/unit/send-get/get_array)
477487
add_mpi_test(get_self 2 ${tests_root}/unit/send-get/get_self)
@@ -508,7 +518,9 @@ if(opencoarrays_aware_compiler)
508518
# GFortran PR 78505 only fixed on trunk/gcc 7
509519
add_mpi_test(source-alloc-no-sync 8 ${tests_root}/regression/reported/source-alloc-sync)
510520
endif()
511-
add_mpi_test(convert-before-put 3 ${tests_root}/regression/reported/convert-before-put)
521+
if (RUN_DEVELOPER_TESTS)
522+
add_mpi_test(convert-before-put 3 ${tests_root}/regression/reported/convert-before-put)
523+
endif()
512524
add_mpi_test(event-post 3 ${tests_root}/regression/reported/event-post)
513525
add_mpi_test(co_reduce-factorial 4 ${tests_root}/regression/reported/co_reduce-factorial)
514526
add_mpi_test(co_reduce-factorial-int8 4 ${tests_root}/regression/reported/co_reduce-factorial-int8)

0 commit comments

Comments
 (0)