diff --git a/core/modules/simpletest/src/WebTestBase.php b/core/modules/simpletest/src/WebTestBase.php
index 8e29d46..b028c58 100644
--- a/core/modules/simpletest/src/WebTestBase.php
+++ b/core/modules/simpletest/src/WebTestBase.php
@@ -448,16 +448,45 @@ protected function findBlockInstance(Block $block) {
   }
 
   /**
-   * Gets a list files that can be used in tests.
+   * Gets a list of files that can be used in tests.
+   *
+   * The first time this method is called, the class will generate a bunch of
+   * test files in text and in binary format. These files are stored in
+   * public:// and can be used for tests. It will copy all files in
+   * core/modules/simpletest/files to public:// as well. These contain image,
+   * SQL, PHP, JavaScript and HTML files.
+   *
+   * All files are prefixed with their type:
+   * - text-*.txt and text-* (no extension)
+   * - binary-* (no extension)
+   * - html-*.html
+   * - image-*.png, image-*.jpg and image-*.gif
+   * - javascript-*.txt and javascript-*.script
+   * - php-*.txt and php-*.php
+   * - sql-*.txt and sql-*.sql
+   *
+   * Any subsequent calls will not generate any new files, or copy the files
+   * over again. However, if a test class adds a new file to public:// that
+   * is prefixed with one of the above types, it will get returned as well, even
+   * on subsequent calls.
    *
    * @param $type
    *   File type, possible values: 'binary', 'html', 'image', 'javascript',
    *   'php', 'sql', 'text'.
    * @param $size
-   *   File size in bytes to match. Please check the tests/files folder.
+   *   (optional) File size in bytes to match. Defaults to NULL, which will not
+   *   filter the returned list by size. The files generated by this function
+   *   are of the following sizes (in bytes):
+   *   - binary: 16, 256, 1024, 2048, and 20480
+   *   - html: 24
+   *   - sql: 41
+   *   - php: 44, and 47
+   *   - javascript: 57, and 58
+   *   - text: 64, and 1024
+   *   - image: 125, 183, 964, 1831, 1901, and 39325
    *
    * @return
-   *   List of files that match filter.
+   *   List of files in public:// that match the filter(s).
    */
   protected function drupalGetTestFiles($type, $size = NULL) {
     if (empty($this->generatedTestFiles)) {
