[Rt-commit] rt branch, 4.4/document-tmpfs-for-faster-tests, created. rt-4.4.4-125-gab8f408ed1

Dianne Skoll dianne at bestpractical.com
Thu Jul 16 14:20:30 EDT 2020


The branch, 4.4/document-tmpfs-for-faster-tests has been created
        at  ab8f408ed13e5d067acfb7cb9d64e00754bafea1 (commit)

- Log -----------------------------------------------------------------
commit ab8f408ed13e5d067acfb7cb9d64e00754bafea1
Author: Dianne Skoll <dianne at bestpractical.com>
Date:   Thu Jul 16 14:19:40 2020 -0400

    Document speeding up tests by using a tmpfs file system for SQLite files.
    
    Added a brief paragraph to hacking.pod.

diff --git a/docs/hacking.pod b/docs/hacking.pod
index 15742fb759..e366d6bdcd 100644
--- a/docs/hacking.pod
+++ b/docs/hacking.pod
@@ -214,6 +214,21 @@ running the tests in parallel.
 
     RT_TEST_PARALLEL=1 prove -l -j4 t/customfields/*.t
 
+=head2 Improving Test Performance
+
+For best test performance, you should use a SQLite database type.  Furthermore,
+you should put the t/tmp directory in a RAM-based filesystem.  This will
+eliminate the overhead of SQLite's calls to C<fsync> or equivalent.
+
+On Linux, for example, you can create a RAM-based file system and link
+it to t/tmp as follows:
+
+    mkdir /ram                  # Or your preferred location
+    chown my_user /ram
+    mount -t tmpfs none /ram
+    rm -rf rt/t/tmp
+    ln -s /ram rt/t/tmp
+
 =head2 Tests with Docker
 
 RT has a Dockerfile that can be used to run the test suite for some configurations.

-----------------------------------------------------------------------


More information about the rt-commit mailing list