diff --git a/core/apcu_saver.php b/core/apcu_saver.php
new file mode 100644
index 0000000000..b392da637f
--- /dev/null
+++ b/core/apcu_saver.php
@@ -0,0 +1,12 @@
+<?php
+chdir('..');
+
+$count = (int) file_get_contents('sites/default/files/simpletest/tests-counter.txt') ?: 0;
+file_put_contents('sites/default/files/simpletest/tests-counter.txt', ++$count);
+
+if ($count % 100 === 0) {
+  $logfile = 'sites/default/files/simpletest/apcu_entries_' . date("Y-m-d-h-i-s") . '.log.gz';
+  $info = apcu_cache_info();
+  file_put_contents($logfile, gzencode(json_encode($info['cache_list']), 9));
+  apcu_clear_cache();
+}
diff --git a/core/scripts/run-tests.sh b/core/scripts/run-tests.sh
index 5a8ecd99c2..71db42d98f 100644
--- a/core/scripts/run-tests.sh
+++ b/core/scripts/run-tests.sh
@@ -143,6 +143,7 @@
 }
 
 $test_list = simpletest_script_get_test_list();
+$test_list = array_slice($test_list, 0, 100, TRUE);
 
 // Try to allocate unlimited time to run the tests.
 drupal_set_time_limit(0);
diff --git a/core/tests/Drupal/Tests/BrowserTestBase.php b/core/tests/Drupal/Tests/BrowserTestBase.php
index 3260f6ea01..c4d0fdb812 100644
--- a/core/tests/Drupal/Tests/BrowserTestBase.php
+++ b/core/tests/Drupal/Tests/BrowserTestBase.php
@@ -548,6 +548,8 @@ protected function cleanupEnvironment() {
    * {@inheritdoc}
    */
   protected function tearDown() {
+    $this->drupalGet($GLOBALS['base_url'] . '/core/apcu_saver.php');
+
     parent::tearDown();
 
     // Destroy the testing kernel.
