diff options
author | John Szakmeister <john@szakmeister.net> | 2015-03-09 05:47:48 -0400 |
---|---|---|
committer | John Szakmeister <john@szakmeister.net> | 2015-03-09 05:47:48 -0400 |
commit | 638452da2a5650dcee3eefa84f037d2920abbb76 (patch) | |
tree | 7b2625dfa923c80e141011e7a817f547069fec76 | |
parent | 973b5135ccc628112b869970ef86cdc2646a8ecd (diff) | |
parent | d8ef23849af0e57a35a87d477a468a9241f78ad8 (diff) | |
download | rneovim-638452da2a5650dcee3eefa84f037d2920abbb76.tar.gz rneovim-638452da2a5650dcee3eefa84f037d2920abbb76.tar.bz2 rneovim-638452da2a5650dcee3eefa84f037d2920abbb76.zip |
Merge pull request #2082 from jszakmeister/fixes-for-busted-and-luajit
tests: prevent busted from reloading the ffi module and others
-rw-r--r-- | cmake/RunTests.cmake | 1 | ||||
-rw-r--r-- | test/functional/preload.lua | 5 | ||||
-rw-r--r-- | test/unit/preload.lua | 7 |
3 files changed, 13 insertions, 0 deletions
diff --git a/cmake/RunTests.cmake b/cmake/RunTests.cmake index 8f303bae2e..a4330a58de 100644 --- a/cmake/RunTests.cmake +++ b/cmake/RunTests.cmake @@ -15,6 +15,7 @@ endif() execute_process( COMMAND ${BUSTED_PRG} -v -o ${BUSTED_OUTPUT_TYPE} + --helper=${TEST_DIR}/${TEST_TYPE}/preload.lua --lpath=${BUILD_DIR}/?.lua ${TEST_PATH} WORKING_DIRECTORY ${WORKING_DIR} ERROR_VARIABLE err diff --git a/test/functional/preload.lua b/test/functional/preload.lua new file mode 100644 index 0000000000..5f34f7fa6e --- /dev/null +++ b/test/functional/preload.lua @@ -0,0 +1,5 @@ +-- Modules loaded here will not be cleared and reloaded by Busted. +-- Busted started doing this to help provide more isolation. See issue #62 +-- for more information about this. +local ffi = require('ffi') +local helpers = require('test.functional.helpers') diff --git a/test/unit/preload.lua b/test/unit/preload.lua new file mode 100644 index 0000000000..d8ec2c3943 --- /dev/null +++ b/test/unit/preload.lua @@ -0,0 +1,7 @@ +-- Modules loaded here will not be cleared and reloaded by Busted. +-- Busted started doing this to help provide more isolation. See issue #62 +-- for more information about this. +local ffi = require('ffi') +local helpers = require('test.unit.helpers') +local lfs = require('lfs') +local preprocess = require('test.unit.preprocess') |