diff --git a/core/modules/simpletest/simpletest.api.php b/core/modules/simpletest/simpletest.api.php
index e5251b7..628a326 100644
--- a/core/modules/simpletest/simpletest.api.php
+++ b/core/modules/simpletest/simpletest.api.php
@@ -46,7 +46,7 @@ function hook_test_group_finished() {
  *
  * This hook is called when an individual test has finished.
  *
- * @param
+ * @param array $results
  *   $results The results of the test as gathered by
  *   \Drupal\simpletest\WebTestBase.
  *
diff --git a/core/modules/simpletest/simpletest.module b/core/modules/simpletest/simpletest.module
index 7c0c34f..b8fa8df 100644
--- a/core/modules/simpletest/simpletest.module
+++ b/core/modules/simpletest/simpletest.module
@@ -1,4 +1,8 @@
 <?php
+/**
+ * @file
+ * Provides testing functionality.
+ */
 
 use Drupal\Core\Database\Database;
 use Drupal\Core\Extension\ExtensionDiscovery;
@@ -9,11 +13,6 @@
 use Symfony\Component\Process\PhpExecutableFinder;
 
 /**
- * @file
- * Provides testing functionality.
- */
-
-/**
  * Implements hook_help().
  */
 function simpletest_help($route_name, RouteMatchInterface $route_match) {
@@ -114,7 +113,7 @@ function _simpletest_format_summary_line($summary) {
 /**
  * Runs tests.
  *
- * @param $test_list
+ * @param array $test_list
  *   List of tests to run.
  *
  * @return string
@@ -165,9 +164,9 @@ function simpletest_run_tests($test_list) {
 /**
  * Executes PHPUnit tests and returns the results of the run.
  *
- * @param $test_id
+ * @param int $test_id
  *   The current test ID.
- * @param $unescaped_test_classnames
+ * @param array $unescaped_test_classnames
  *   An array of test class names, including full namespaces, to be passed as
  *   a regular expression to PHPUnit's --filter option.
  *
@@ -204,7 +203,7 @@ function simpletest_process_phpunit_results($phpunit_results) {
 /**
  * Returns the path to use for PHPUnit's --log-junit option.
  *
- * @param $test_id
+ * @param int $test_id
  *   The current test ID.
  *
  * @return string
@@ -234,7 +233,7 @@ function simpletest_phpunit_configuration_filepath() {
  *   A filepath to use for PHPUnit's --log-junit option.
  *
  * @return string
- *  The results as returned by exec().
+ *   The results as returned by exec().
  */
 function simpletest_phpunit_run_command(array $unescaped_test_classnames, $phpunit_file) {
   $phpunit_bin = simpletest_phpunit_command();
@@ -360,6 +359,24 @@ function _simpletest_batch_operation($test_list_init, $test_id, &$context) {
   $context['finished'] = 1 - $size / $max;
 }
 
+/**
+ * Batch finished callback.
+ *
+ * Tell the user that the tests are finished, and invoke
+ * hook_test_group_finished().
+ *
+ * @param bool $success
+ *   Whether or not the batch was successful.
+ * @param array $results
+ *   Array of results.
+ * @param array $operations
+ *   Operations remaining if $success is FALSE.
+ * @param string $elapsed
+ *   Time elapsed.
+ *
+ * @see callback_batch_finished()
+ * @see hook_test_group_finished()
+ */
 function _simpletest_batch_finished($success, $results, $operations, $elapsed) {
   if ($success) {
     drupal_set_message(t('The test run finished in @elapsed.', array('@elapsed' => $elapsed)));
@@ -383,8 +400,9 @@ function _simpletest_batch_finished($success, $results, $operations, $elapsed) {
 /**
  * Get information about the last test that ran given a test ID.
  *
- * @param $test_id
+ * @param int $test_id
  *   The test ID to get the last test from.
+ *
  * @return array
  *   Array containing the last database prefix used and the last test class
  *   that ran.
@@ -409,11 +427,11 @@ function simpletest_last_test_get($test_id) {
  * The errors in the log should only be fatal errors since any other errors
  * will have been recorded by the error handler.
  *
- * @param $test_id
+ * @param int $test_id
  *   The test ID to which the log relates.
- * @param $database_prefix
+ * @param string $database_prefix
  *   The database prefix to which the log relates.
- * @param $test_class
+ * @param string $test_class
  *   The test class to which the log relates.
  *
  * @return bool
@@ -590,7 +608,7 @@ function simpletest_clean_temporary_directories() {
 /**
  * Clears the test result tables.
  *
- * @param $test_id
+ * @param int $test_id
  *   Test ID to remove results for, or NULL to remove all results.
  *
  * @return int
@@ -638,9 +656,9 @@ function simpletest_mail_alter(&$message) {
 /**
  * Converts PHPUnit's JUnit XML output to an array.
  *
- * @param $test_id
+ * @param int $test_id
  *   The current test ID.
- * @param $phpunit_xml_file
+ * @param string $phpunit_xml_file
  *   Path to the PHPUnit XML file.
  *
  * @return array[]
diff --git a/core/modules/simpletest/tests/src/Unit/PhpUnitErrorTest.php b/core/modules/simpletest/tests/src/Unit/PhpUnitErrorTest.php
index 0a82609..fe5bc5e 100644
--- a/core/modules/simpletest/tests/src/Unit/PhpUnitErrorTest.php
+++ b/core/modules/simpletest/tests/src/Unit/PhpUnitErrorTest.php
@@ -1,5 +1,10 @@
 <?php
 
+/**
+ * @file
+ * Contains \Drupal\simpletest\Tests\PhpUnitErrorTest
+ */
+
 namespace Drupal\Tests\simpletest\Unit;
 
 use Drupal\Tests\UnitTestCase;
diff --git a/core/modules/simpletest/tests/src/Unit/TestBaseTest.php b/core/modules/simpletest/tests/src/Unit/TestBaseTest.php
index 9bac4fc..334b3af 100644
--- a/core/modules/simpletest/tests/src/Unit/TestBaseTest.php
+++ b/core/modules/simpletest/tests/src/Unit/TestBaseTest.php
@@ -32,7 +32,7 @@ class TestBaseTest extends UnitTestCase {
    * @return array
    *   An array of values passed to the test method.
    */
-  public function randomStringValidateProvider () {
+  public function randomStringValidateProvider() {
     return array(
       array(' curry paste', FALSE),
       array('curry paste ', FALSE),
@@ -53,7 +53,7 @@ class TestBaseTest extends UnitTestCase {
    * @param bool $expected
    *   The expected result of the validation.
    *
-   * @see \Drupal\simpletest\TestBase::randomStringValidate().
+   * @see \Drupal\simpletest\TestBase::randomStringValidate()
    *
    * @dataProvider randomStringValidateProvider
    * @covers ::randomStringValidate
