gitlab.com/cznic/sqlite.git@v1.0.0/testdata/mptest/config02.test (about)

     1  /*
     2  ** Configure five tasks in different ways, then run tests.
     3  */
     4  PRAGMA page_size=512;
     5  --task 1
     6    PRAGMA mmap_size=0;
     7  --end
     8  --task 2
     9    PRAGMA mmap_size=28672;
    10  --end
    11  --task 3
    12    PRAGMA mmap_size=8192;
    13  --end
    14  --task 4
    15    PRAGMA mmap_size=65536;
    16  --end
    17  --task 5
    18    PRAGMA mmap_size=268435456;
    19  --end
    20  --source multiwrite01.test
    21  --source crash02.subtest
    22  PRAGMA page_size=1024;
    23  VACUUM;
    24  CREATE TABLE pgsz(taskid, sz INTEGER);
    25  --task 1
    26    INSERT INTO pgsz VALUES(1, eval('PRAGMA page_size'));
    27  --end
    28  --task 2
    29    INSERT INTO pgsz VALUES(2, eval('PRAGMA page_size'));
    30  --end
    31  --task 3
    32    INSERT INTO pgsz VALUES(3, eval('PRAGMA page_size'));
    33  --end
    34  --task 4
    35    INSERT INTO pgsz VALUES(4, eval('PRAGMA page_size'));
    36  --end
    37  --task 5
    38    INSERT INTO pgsz VALUES(5, eval('PRAGMA page_size'));
    39  --end
    40  --source multiwrite01.test
    41  --source crash02.subtest
    42  --wait all
    43  SELECT sz FROM pgsz;
    44  --match 1024 1024 1024 1024 1024
    45  PRAGMA page_size=2048;
    46  VACUUM;
    47  DELETE FROM pgsz;
    48  --task 1
    49    INSERT INTO pgsz VALUES(1, eval('PRAGMA page_size'));
    50  --end
    51  --task 2
    52    INSERT INTO pgsz VALUES(2, eval('PRAGMA page_size'));
    53  --end
    54  --task 3
    55    INSERT INTO pgsz VALUES(3, eval('PRAGMA page_size'));
    56  --end
    57  --task 4
    58    INSERT INTO pgsz VALUES(4, eval('PRAGMA page_size'));
    59  --end
    60  --task 5
    61    INSERT INTO pgsz VALUES(5, eval('PRAGMA page_size'));
    62  --end
    63  --source multiwrite01.test
    64  --source crash02.subtest
    65  --wait all
    66  SELECT sz FROM pgsz;
    67  --match 2048 2048 2048 2048 2048
    68  PRAGMA page_size=8192;
    69  VACUUM;
    70  DELETE FROM pgsz;
    71  --task 1
    72    INSERT INTO pgsz VALUES(1, eval('PRAGMA page_size'));
    73  --end
    74  --task 2
    75    INSERT INTO pgsz VALUES(2, eval('PRAGMA page_size'));
    76  --end
    77  --task 3
    78    INSERT INTO pgsz VALUES(3, eval('PRAGMA page_size'));
    79  --end
    80  --task 4
    81    INSERT INTO pgsz VALUES(4, eval('PRAGMA page_size'));
    82  --end
    83  --task 5
    84    INSERT INTO pgsz VALUES(5, eval('PRAGMA page_size'));
    85  --end
    86  --source multiwrite01.test
    87  --source crash02.subtest
    88  --wait all
    89  SELECT sz FROM pgsz;
    90  --match 8192 8192 8192 8192 8192
    91  PRAGMA page_size=16384;
    92  VACUUM;
    93  DELETE FROM pgsz;
    94  --task 1
    95    INSERT INTO pgsz VALUES(1, eval('PRAGMA page_size'));
    96  --end
    97  --task 2
    98    INSERT INTO pgsz VALUES(2, eval('PRAGMA page_size'));
    99  --end
   100  --task 3
   101    INSERT INTO pgsz VALUES(3, eval('PRAGMA page_size'));
   102  --end
   103  --task 4
   104    INSERT INTO pgsz VALUES(4, eval('PRAGMA page_size'));
   105  --end
   106  --task 5
   107    INSERT INTO pgsz VALUES(5, eval('PRAGMA page_size'));
   108  --end
   109  --source multiwrite01.test
   110  --source crash02.subtest
   111  --wait all
   112  SELECT sz FROM pgsz;
   113  --match 16384 16384 16384 16384 16384
   114  PRAGMA auto_vacuum=FULL;
   115  VACUUM;
   116  --source multiwrite01.test
   117  --source crash02.subtest
   118  --wait all
   119  PRAGMA auto_vacuum=FULL;
   120  PRAGMA page_size=512;
   121  VACUUM;
   122  --source multiwrite01.test
   123  --source crash02.subtest