aboutsummaryrefslogtreecommitdiffstats
path: root/lib/kernel/test/prim_file_SUITE.erl
AgeCommit message (Collapse)Author
2016-05-27kernel: Don't test negative time values in file infoBjörn-Egil Dahlberg
2016-04-13Merge branch 'henrik/update-copyrightyear'Henrik Nord
* henrik/update-copyrightyear: update copyright-year
2016-04-04Don't check dates before 1970Björn-Egil Dahlberg
2016-03-31Log additional test information in prim_file_SUITEBjörn-Egil Dahlberg
2016-03-31Relax file_info testsBjörn-Egil Dahlberg
2016-03-15update copyright-yearHenrik Nord
2016-03-10Remove ?line macrosBjörn Gustavsson
While we are it, also re-ident the files.
2016-03-10Fix commentsBjörn Gustavsson
Remove out-commented code. Make sure that comments that are not at the end of a line starts with two '%' characters and not just one. That will become important later when we'll remove all ?line macros and ask Emacs to re-indent the files.
2016-03-10Eliminate use of doc and suite clausesBjörn Gustavsson
Those clause are obsolete and never used by common_test.
2016-03-10Eliminate use test_server:format()Björn Gustavsson
Replace with io:format/2 or ct:pal/3.
2016-03-10Eliminate use of test_server:sleep/1Björn Gustavsson
2016-03-09Eliminate use of test_server:fail/0,1Björn Gustavsson
2016-03-09Eliminate use of ?config() macroBjörn Gustavsson
?config is ugly and not recommended. Use proplists:get_value/2 instead.
2016-03-09Modernize timetrapsBjörn Gustavsson
2016-02-17Eliminate use of test_server.hrl and test_server_line.hrlBjörn Gustavsson
As a first step to removing the test_server application as as its own separate application, change the inclusion of test_server.hrl to an inclusion of ct.hrl and remove the inclusion of test_server_line.hrl.
2015-07-10ose: Remove all code related to the OSE portLukas Larsson
The OSE port is no longer supported and this commit removed it and any changes related to it. The things that were general improvements have been left in the code.
2015-06-18Change license text to APLv2Bruce Yinhe
2014-12-02fix eacces spellingMikael Pettersson
2014-03-24Merge branch 'sverk/win-long-filenames/OTP-11813'Sverker Eriksson
* sverk/win-long-filenames/OTP-11813: erts: Cleanup debug tracing in win_efile.c erts: Fix file:list_dir for windows paths 258 or 259 chars long erts: Increase MAXPATHLEN to 4096 for windows erts: Fix bug in efile_readlink for long win paths kernel: Fix failed tests in prim_file_SUITE for windows erts: Fix compiler warning in win_efile.c erts: Skip tests of paths longer than 255 characters as atoms erts: Skip tests of file:set_cwd for too long path on Windows erts: Make file:make_symlink/2 return {error,eperm} on Windows erts: Revert file:set_cwd impl for windows erts: Ignore reduntant slashes in windows paths fix file_SUITE:cur_dir_0 for long windows paths erts: Fix file_SUITE:make_del_dir for long paths erts: Fix long windows paths for compressed files erts: Use GetFullPathNameW to construct abs paths from relative ones erts: Fix file driver to handle long paths on windows Conflicts: erts/emulator/drivers/win32/win_efile.c
2014-03-24kernel: Fix failed tests in prim_file_SUITE for windowsSverker Eriksson
2014-02-28prim_file_SUITE: Remove the short 5 seconds timetrap timeoutBjörn Gustavsson
Several tests cases would typically fail because of a timetrap timeout on our older test machines running with a Linux kernel with a lower version than 2.6.30 and the ext3 file system. In http://lwn.net/Articles/328363/, the author desribes peformance issues with ext3 that were fixed in 2.6.30. Since common_test nowadays has a default timetrap timeout, there is no need to explicitly set a timeout in each test case (except for prolonging the default timeout).
2014-02-24ose: efile driver updates.Jonas Karlsson
2014-02-24ose: Bugfixes to filesystem related issues.Jonas Karlsson
2014-02-24ose: Adapt suite for OSERasmuss Graaf
2013-06-04Delete 'icky' dirs and symlinks after kernel testsSiri Hansen
This is to avoid lingering files on windows.
2013-02-22Update copyright yearsBjörn-Egil Dahlberg
2013-02-11prim_file: Add list_dir_all() and read_link_all()Björn Gustavsson
2013-02-08Test that list_dir("non-existing-dir") fails with the correct errorBjörn Gustavsson
2013-01-09Add file:allocate/3 operationFilipe David Manana
This operation allows pre-allocation of space for files. It succeeds only on systems that support such operation. The POSIX standard defines the optional system call posix_fallocate() to implement this feature. However, some systems implement more specific functions to accomplish the same operation. On Linux, if the more specific function fallocate() is implemented, it is used instead of posix_fallocate(), falling back to posix_fallocate() if the fallocate() call failed (it's only supported for the ext4, ocfs2, xfs and btrfs file systems at the moment). On Mac OS X it uses the specific fcntl() operation F_PREALLOCATE, falling back to posix_fallocate() if it's available (at the moment Mac OS X doesn't provide posix_fallocate()). On any other UNIX system, it uses posix_fallocate() if it's available. Any other system not providing this system call or any function to pre-allocate space for files, this operation always fails with the ENOTSUP POSIX error.
2012-07-19kernel: Remove VxWorks from testsBjörn-Egil Dahlberg
2011-12-21prim_file_SUITE: large_file success depends on wordsizeRaimo Niskanen
Check VM wordsize to see if a driver command with data larger than 32-bit size is supposed to succeed. On wordsize 4 machines (32-bit) {error,einval} is expected since the total size passed to a driver can not exceed sizeof(ErlDrvSizeT).
2011-12-20file_SITE,prim_file_SUITE: Accept old OpenBSD pecularityRaimo Niskanen
2011-12-20prim_file_SUITE: large_write - meaner test data and check result contentRaimo Niskanen
2011-12-20prim_file_SUITE: Add large_write/1Björn Gustavsson
Test writing slightly more than 4GB as an io list with smaller binaries.
2011-12-08Remove time_t specific test in prim_file_SUITEBjörn-Egil Dahlberg
Remove time_t = Sint64 | Uint32 testcase only. The year 2040 does not exist on Sint32.
2011-12-08Change options to prim_file:*_file_info/*Björn-Egil Dahlberg
* 'utc' changed to 'universal' * 'epoch' changed to 'posix' This change conforms to other naming already in OTP, e.g. erlang:universaltime_to_localtime/1.
2011-12-08Add file_info_opt tests in prim_file_SUITEBjörn-Egil Dahlberg
2011-05-18Fix bug in make_del_dir testcasesPatrik Nyblom
2011-05-12Teach (prim_)file_SUITE about directory access on WindowsPatrik Nyblom
2011-03-11Update copyright yearsBjörn-Egil Dahlberg
2011-02-17Rename Suite Callback to Common Test HookLukas Larsson
2011-02-17Fix formatting for kernelLukas Larsson
2011-02-17Add init_per_suite and end_per_suiteLukas Larsson
2011-02-17Add ts_install_scb to suite/0Lukas Larsson
2011-02-17Update kernel tests to conform with common_test standardLukas Larsson
2010-06-04Support opening files in exclusive modeMichael Santos
Add an option that atomically tests for the existence of a file and creates it if the file does not exist, by passing the O_EXCL flag to open() on Unix and CREATE_NEW flag on Windows. Support for O_EXCL varies across platforms and filesystems. {ok, Fd} = file:open("/tmp/foo", [write,exclusive]), {error, eexist} = file:open("/tmp/foo", [write,exclusive]).
2010-05-20Add file:advise/4 - a wrapper to the POSIX syscall posix_fadviseFilipe David Manana
Useful for informing the Operating System about the access pattern for a file's data, so that it can adapt the caching strategy to maximize disk IO performance.
2010-05-20Add file:datasync/1 for syncing file contents onlyFilipe David Manana
file:datasync/1 invokes the POSIX system call "int fdatasync(int fd)". This system call is similar to "fsync" but, unlike fsync, it does not update the metadata associated with the file (like the access time for example). It's used by many DBMSs (MySQL and SQLite of example) to increase disk IO performance, as it avoids disk seeks and disk write operations compared to fsync. More details on it at: http://linux.die.net/man/2/fdatasync An example, from the MySQL source: http://bazaar.launchpad.net/~mysql/mysql-server/mysql-5.1-telco-6.1/annotate/head%3A/mysys/my_sync.c#L61 This new function just calls fsync on systems not implementing fdatasync.
2010-05-06Merge branch 'bg/file-del_dir' into devErlang/OTP
* bg/file-del_dir: Adjust test of file:del_dir("..") to accept {error,einval}
2010-05-05Adjust test of file:del_dir("..") to accept {error,einval}Björn Gustavsson
On FreeBSD, file:del_dir("..") will return {error,einval} rather than the expected {error,eexist}, and so will file:del_dir("../.."), and so on. It could be argued that we should change the implementation of file:del_dir/1 to remap the error code (as some other error codes are remapped to reduce the differences between different platforms), but the consistency gained does not seem to be worth the effort. Therefore, until we'll find a real-world use case where it is essential to have consistent error codes for file:del_dir("..") on all platforms, change the test case to accept both errors.