mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-02 17:26:17 +01:00
tests: Skip >4GB file tests unless running tests in slow/thorough mode
They take too long to include in a normal test run. They’ll still be run in CI once a week as part of our scheduled slow test job. Signed-off-by: Philip Withnall <pwithnall@gnome.org>
This commit is contained in:
parent
a8be45204e
commit
1f838b061b
@ -2938,6 +2938,15 @@ create_testfile_4gb_or_skip (char *filename)
|
|||||||
int fd;
|
int fd;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
|
/* Reading each 4GB test file takes about 5s on a fast machine, and another 7s
|
||||||
|
* to compare its contents once it’s been read. That’s too slow for a normal
|
||||||
|
* test run, and there’s no way to speed it up. */
|
||||||
|
if (!g_test_slow ())
|
||||||
|
{
|
||||||
|
g_test_skip ("Skipping slow >4GB file test");
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
fd = g_mkstemp (filename);
|
fd = g_mkstemp (filename);
|
||||||
g_assert_cmpint (fd, !=, -1);
|
g_assert_cmpint (fd, !=, -1);
|
||||||
ret = ftruncate (fd, testfile_4gb_size);
|
ret = ftruncate (fd, testfile_4gb_size);
|
||||||
|
Loading…
Reference in New Issue
Block a user