aboutsummaryrefslogtreecommitdiff
path: root/test/unit/os/fs_spec.lua
Commit message (Collapse)AuthorAge
* build: Target luacheck HEAD.Justin M. Keyes2016-11-17
| | | | | | | | | | | | https://github.com/mpeterv/luacheck/pull/81#issuecomment-261099606 > If you really want to use bleeding-edge version you should get the > rockspec from master branch, not a fixed commit ... > The correct way to install from a specific commit is cloning that > commit and running "luarocks make" from project directory. The reason > is that running "install" or "build" on an scm rockspec fetches > sources from master but uses build description from the rockspec > itself, which may be outdated.
* os/fs: Rename os_file_exists to os_path_exists (#4973)Daniel Xu2016-07-06
| | | | Because the old name did not indicate that the function would return true on directories as well.
* unittests: Fix bug somewhere that makes file_read tests SEGVZyX2016-06-24
|
* unittests: Add tests for file.cZyX2016-06-24
| | | | Also fixes some errors found.
* unittests: Add os_write testZyX2016-06-23
| | | New os/fs.c functions are now all tested.
* unittests: Add os_close, os_read and os_readv testsZyX2016-06-23
|
* os_nodetype: Return NODE_NORMAL if os_stat fails.Justin M. Keyes2016-05-22
| | | | | | | | Conforms to Vim's mch_nodetype. Regression by 7db4a15. buf_write() expects NODE_WRITABLE for character devices such as /dev/stderr. Closes #4772
* vim-patch:7.4.672KillTheMule2016-05-02
| | | | | | | | | | | Problem: When completing a shell command, directories in the current directory are not listed. Solution: When "." is not in $PATH also look in the current directory for directories. https://github.com/vim/vim/commit/b5971141dff0c69355fd64196fcc0d0d071d4c82 Most of it applied manually.
* test: sys/fcntl.h -> fcntl.hMichael Reed2016-01-14
| | | | | | | | | POSIX.1-2008[1] says that the latter should be used, and all of our supported platforms would seem to support this scheme, apparently even Windows[2]. [1]: http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/fcntl.h.html [2]: https://msdn.microsoft.com/en-us/library/z0kc8e3z.aspx
* Use libuv errors instead of errno in unit testsRui Abreu Ferreira2015-11-25
| | | | | | | | Replaced old unit tests for errno with libuv error codes UV_ENOENT and UV_EEXIST (for os_open and os_getperms). Added libuv include path to test/includes compiler calls - needed to get hold of libuv headers.
* test/unit: clean up according to luacheckMarco Hinz2015-11-23
|
* os/fs: Allow os_mkdir_recurse directory name to end with ///ZyX2015-10-23
|
* os/fs.c: remove os_file_is_readonly()Justin M. Keyes2015-08-17
| | | | | | | | | | | | | | | | | | | os_file_is_readonly() in its current form is equivalent to !os_file_is_writable(). This does not appear to be a bug, because Vim's use of check_file_readonly() (which we changed to os_file_is_readonly()) is equivalent to !os_file_is_writable() in every case. os_file_is_readonly() also fails this test: returns false if the file is non-read, non-write A more useful form would define behavior under these cases: - path is executable (but not writable) - path is non-existent - path is directory But there is no reason for os_file_is_readonly() to exist, so remove it.
* test: more cases for os_file_is_readonly()Justin M. Keyes2015-08-17
|
* test: cover os_file_is_readable()Justin M. Keyes2015-08-17
|
* test: fix pending() invocationsJustin M. Keyes2015-08-09
| | | | | AFAICT busted does not report pending() invocations without the 2nd argument.
* os/fs: Move mkdir_recurse from eval.c to os/fs.cZyX2015-07-26
|
* event loop: New abstraction layer with refactored time/signal APIThiago de Arruda2015-07-17
| | | | | | | | | | - Add event loop abstraction module under src/nvim/event. The src/nvim/event/loop module replaces src/nvim/os/event - Remove direct dependency on libuv signal/timer API and use the new abstraction instead. - Replace all references to uv_default_loop() by &loop.uv, a new global variable that wraps libuv main event loop but allows the event loop functions to be reused in other contexts.
* tests: Use pending() instead of silently skipping test. #2737Florian Walch2015-05-29
|
* Use lfs.currentdir() to fix symlink test fail.Rich Churcher2015-04-01
|
* Merge pull request #1965 from jszakmeister/fix-fs-spec-test-for-freebsdJohn Szakmeister2015-02-11
|\ | | | | Fix an fs_spec test under FreeBSD and a symlinked home directory.
| * Fix an fs_spec test under FreeBSD and a symlinked home directory.John Szakmeister2015-02-09
| | | | | | | | | | | | | | | | | | | | It turns out the FreeBSD 10 VM has a symlink for the home directory to /usr/home. Unfortunately, this breaks the test as arg[0] may not have the symlink resolved, but the path returned from the exe() call will. As a result, the comparison fails, even though the result is correct. Let's fix this by running the absolute path through exe() too, and then comparing the results.
* | Get rid of a bashism in the fs_spec test. #1964John Szakmeister2015-02-09
|/ | | | | FreeBSD doesn't use bash by default, causing the group id to be print out in the middle of the test.
* test/os/fs: fix call to lfs.attributesNicolas Hillegeer2015-01-16
| | | | | | | | The second argument to lfs.attributes() serves only to select a specific part of the normally returned table. It's not a file open flag (e.g.: as for fopen() in C). Also made the (n)eq checks a bit more idiomatic. Fixes #1831
* update os_can_exe unit testScott Prager2014-09-17
|
* vim-patch:7.4.235Scott Prager2014-09-17
| | | | | | | Problem: It is not easy to get the full path of a command. Solution: Add the exepath() function. https://code.google.com/p/vim/source/detail?r=5ab2946f7ce560985830fbc3c453bb0f7a01f385
* unit tests: avoid global scope; add missing cimportsJustin M. Keyes2014-09-11
| | | | temporarily comment out call to vim_deltempdir() to avoid segfault
* fileid: rename os_file_id_equal_file_infoStefan Hoffmann2014-08-31
|
* fileid: rename os_file_id_equalStefan Hoffmann2014-08-31
|
* fileid: rename os_get_file_idStefan Hoffmann2014-08-31
|
* fileinfo: rename os_file_info_get_inodeStefan Hoffmann2014-08-31
|
* fileinfo: rename os_file_info_get_idStefan Hoffmann2014-08-31
|
* fileinfo: rename os_file_info_id_equalStefan Hoffmann2014-08-31
|
* fileinfo: rename os_get_file_info{,_link,_fd}Stefan Hoffmann2014-08-31
|
* fileinfo: implement os_fileinfo_blocksizeStefan Hoffmann2014-08-31
|
* fileinfo: implement os_fileinfo_hardlinksStefan Hoffmann2014-08-31
|
* fileinfo: implement os_fileinfo_sizeStefan Hoffmann2014-08-31
| | | | this replaces os_get_file_size and file_info.stat.st_size
* unittest: Move FileInfo tests one level upStefan Hoffmann2014-08-31
|
* unittest: convert fs_spec.moon to luaThiago de Arruda2014-08-31