aboutsummaryrefslogtreecommitdiff
path: root/test/functional/helpers.lua
Commit message (Collapse)AuthorAge
...
* test/functional: sleep()Justin M. Keyes2016-07-03
|
* test: fix command_count_specBjörn Linse2016-06-23
| | | | The test hit wait_return if x or .x.swp exists in the project root directory.
* functests: Check logs in lua codeZyX2016-06-10
| | | | | | It is otherwise impossible to determine which test failed sanitizer/valgrind check. test/functional/helpers.lua module return was changed so that tests which do not provide after_each function to get new check will automatically fail.
* test: Fix path to valgrind suppressions (#4892)James McCoy2016-06-08
|
* test: rmdir(): recursively deleteJustin M. Keyes2016-06-06
|
* test/functional/helpers.lua: Fix dedent() #4735KillTheMule2016-05-10
| | | | | | The character class %s also matches a newline in lua, that's not really what we want here. It works in the other cases in this function, so I left them, but the final gsub should preserve newlines.
* Satisfy testlint.KillTheMule2016-04-28
| | | | For that, make luatest ignore the preload.lua files.
* Update lua client to 0.0.1-24Thiago de Arruda2016-04-13
| | | | | The new version of the lua client uses libmpack as a backend, and some test scripts had to be updated to reflect that.
* Synchronize shada reset helper with other functional testsThiago de Arruda2016-04-11
|
* tests: update tests to use [gs]et_lines instead of [gs]et_line_sliceBjörn Linse2016-04-01
|
* Remove `goto` statement in lua code.Thiago de Arruda2016-03-07
| | | | `goto` is another luajit extension not compatible with 5.1.
* Remove dependency on ffi moduleThiago de Arruda2016-03-07
|
* tests: Make helper.source() return tempname.watiko2016-01-10
|
* encoding: update testsBjörn Linse2016-01-02
|
* test/functional: Fix api/vim_spec.lua.Rui Abreu Ferreira2015-12-31
| | | | | On Windows the default file format is DOS i.e. newlines are \r\n instead of \n.
* test/functional: clean up according to luacheck (part 2)Marco Hinz2015-11-23
|
* functests: Use . for various folder defaults in testsZyX2015-10-23
|
* functests: Refactor tests:ZyX2015-10-08
| | | | | | | | - Remove unused variables. - Do not use helpers.nvim_feed in most cases. - Do not use helpers.nvim and helpers.nvim_eval at all. - Add helpers.funcs and helpers.\*meths special tables. Indexing such table creates functions which call helpers.call or helpers.nvim (and similar) with first argument equal to table index.
* functests: Make one recover_spec test also use gdb or valgrindZyX2015-10-08
|
* shada,functests: Test how ShaDa support code reacts on errorsZyX2015-10-08
| | | | | | | | | | | | | | Some notes: - Replaced msgpack_unpacker usage with regular xmalloc’ed buffer. Also since msgpack_unpack_next (as well as msgpack_unpacker_next) is not ever going to return MSGPACK_UNPACK_EXTRA_BYTES this condition was checked manually. Function that does return this status is msgpack_unpack, but it is marked as obsolete. - Zero type is checked prior to main switch in shada_read_next_item because otherwise check would be skipped. - Zeroing entry at the start of shada_read_next_item makes it safer. - dedent('') does not work. - v:oldfiles list is only replaced with bang, if it is NULL or empty.
* functests: Add tests for ShaDa variables dumping/readingZyX2015-10-08
|
* shell: Ensure silent bang mappings won't cut outputThiago de Arruda2015-10-01
| | | | | | | Setting `msg_didout` after `call_shell` is enough as it will cause `hit_return_msg()` to print on next line. Close #3269
* functests/helpers: Add exc_exec function that checks the exceptionZyX2015-09-19
|
* api: vim_err_write: add tests for multiline handlingBjörn Linse2015-09-16
|
* encoding: test that `&encoding` cannot be changedBjörn Linse2015-09-08
| | | | Helped-By: Justin M. Keyes <justinkz@gmail.com>
* encoding: Update handling of encoding in testsBjörn Linse2015-09-08
| | | | | | | Always run tests with encoding=utf-8, regardless of user locale Don't set &encoding after startup in tests Helped-By: Michael Reed <m.reed@mykolab.com>
* test59: Store all text as utf-8 and convert when neededBjörn Linse2015-08-26
|
* defaults: set 'laststatus' to 2. #2876Felipe Morales2015-08-24
|
* test: cover :grepJustin M. Keyes2015-08-11
| | | | References #3156
* Test: add new helper function: rmdir()Marco Hinz2015-07-20
| | | | | | | | | - lfs.rmdir() only removes empty directories - os.remove() supercedes lfs.rmdir(); removes files and empty directories - helpers.rmdir() first removes all files within a directory, then the directory itself
* tests: Use write_file() in source().Lucas Hoffmann2015-06-30
|
* tests: Add helpers.write_file() to write short files.Lucas Hoffmann2015-06-30
|
* defaults: enable 'autoindent' #2857Felipe Morales2015-06-20
| | | | Re: https://github.com/neovim/neovim/issues/2676
* test: helpers.lua: add temporary set_session() functionJustin M. Keyes2015-04-12
| | | | | This function is needed until helpers.lua is refactored to support multiple sessions.
* test: Improve functional test debuggability and efficiencyThiago de Arruda2015-03-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | - Read TEST_TAG/TEST_FILTER env vars from cmake/RunTests.cmake. Setting these environment variables will pass --tags/--filter to busted, which can used to filter which tests are executed. - Remove calls to nvim msgpack-rpc API outside tests. This removes the requirement of having a static `clear` call in test/functional/helpers.lua - Use the new busted command-line option "--lazy" to ensure the setup/teardown hooks are only executed when a suite runs at least one test. Now its possible to run/debug a single test like this: ```sh TEST_FILTER='some test string' make test ``` Which will only run tests containing "some test string" in the title. Another option is: ```sh TEST_TAG=some-tag make test ``` After putting #some-tag into the test title. This also improves debugging experience because there will be no unnecessary gdbserver instances whe GDB=1 is passed.
* test: Extract code to spawn nvim into the "spawn" helper functionThiago de Arruda2015-03-24
| | | | | | This is can be used for spawning nvim outside a test context. Also refactor screen.lua to use this function when loading the color map(It is better because the GDB/VALGRIND environment variables are ignored)
* Merge pull request #2075 from jszakmeister/dont-hardcode-tty-test-pathJohn Szakmeister2015-03-01
|\ | | | | tests: don't hardcode the path to tty-test
| * tests: don't hardcode the path to tty-testJohn Szakmeister2015-02-28
| | | | | | | | | | This fixes the build for those who drive the build directly using CMake.
* | tests: require luassert in the helpersJohn Szakmeister2015-03-01
|/ | | | | | | | This is necessary for newer versions of Busted, otherwise assert will be nil and the tests will die. Note: this does not mean the tests now work with the latest Busted. There are still several issues preventing that from happening.
* test: Add synchronization helper for functional testsThiago de Arruda2015-02-16
| | | | | The `wait` function will only return after all input has been processed by nvim. It is useful to time assertions correctly.
* deps: Add Luajit compilation flags to improve debuggingThiago de Arruda2015-02-10
|
* Travis: Fail fast, disable JIT for functional tests.Florian Walch2015-02-02
| | | | Disable JIT to find cause for random `PANIC: unprotected error in call to Lua API` on Travis (OS X).
* test: Fix hanging test suite after failuresThiago de Arruda2015-01-23
| | | | | | | | | | | | | | | | When a test that fails leaves nvim in a 'Press Enter...' state, the whole suite will hang because the `qa!` command executed before the next test won't be processed until '<enter>' is sent. Now the lua client can send a signal with when `Session:exit()` is called, so the `qa!` request is no longer necessary. Also: - Set noswapfile at startup to prevent tests from leaving .s* swap files(should also improve test environment determinism) - Use `assert(false, msg) instead of `error(msg)` to report screen assertion failures.
* test: Set some options to reduce nondeterminism in functional testsThiago de Arruda2015-01-22
| | | | | - shortmess+=I: Remove intro screen - background=light: Disregard COLORFGBG environment variable
* test: Add screen test facilityThiago de Arruda2014-12-09
| | | | | | - Add screen.lua which implements a remote screen to verify screen state by tests under functional/ui - Add some basic screen/highlight tests
* deps: Update lua clientThiago de Arruda2014-12-05
|
* deps: Update bundled lua client versionThiago de Arruda2014-11-25
| | | | | The new version fixes defunct processes which causes random test failures on some systems(#1519)
* test: Add gdbserver support on helpers.luaThiago de Arruda2014-11-23
| | | | | | The $GDB env var can be set to run tests under gdbserver. If $VALGRIND is also set, it will add the --vgdb=yes command-line option to valgrind instead of starting gdbserver.
* test: Refactor functional helpers to use vim_inputThiago de Arruda2014-11-21
| | | | | | | | | | | | | | | | | | | The vim_input function accepts raw terminal input and so is better to emulate real user, especially because it is not deferred as vim_feedkeys. Using this function required a number of changes: - expect() was refactored to use curbuf_contents() - The vim_eval function in request() was moved to curbuf_contents(). For most cases this is enough(we only care for synchronizing api calls with user input when verifying buffer contents). - <C-@>(NUL) is preprocessed before being passed to replace_termcodes. - Legacy test 4 had a bug that only became visible when using vim_input, it is fixed now. - An extra blank line deletion was required for test 101 The last two items show that vim_feedkeys because it is not 100% equivalent to receiving terminal input.
* legacy tests: implement :source helper method.Rainer Borene2014-11-20
|