[CLEANUP] PHPCS issues

Resolves: #49750

Change-Id: If8b144d7d128be0064a506f0fceb2c11ecc419ea
Reviewed-on: https://review.typo3.org/22107
Reviewed-by: Oliver Klee
Tested-by: Oliver Klee
[BUGFIX] Clean tearDown for database testcase tests

Since 6.1 the database handling was changed and introduced
a private variable for the current database name. To get proper
results the sql_select_db() functions have to be changed.

Change-Id: I1e87bddfcfbdc86ab134c2b26e2f02b4e3739349
Resolves: #50212
Reviewed-on: https://review.typo3.org/22436
Reviewed-by: Oliver Klee
Tested-by: Oliver Klee
[CLEANUP] Change the test case class comments to "Test case."

Mentioning the name of the tested class in the test case class PHPDoc is
redundant because the test case class name already contains the name of
the tested class.

In addition, removing the class name from the test case PHPDoc makes our
work easier when we want to rename a class.

Resolves: #50211

Change-Id: I92338193d9a668d2c13d35338848ac748717ae63
Reviewed-on: https://review.typo3.org/22435
Reviewed-by: Nicole Cordes
Tested-by: Nicole Cordes
[BUGFIX] class Tx_Phpunit_FrameworkTest throws error

Error in cleanUpDeletesCreatedDummyUploadFolder because the upload folder
is not removed.

Change-Id: I6abab531b5b9d01bcaa3781d2ba42c1a19bebea6
Resolves: #50213
Reviewed-on: https://review.typo3.org/22437
Reviewed-by: Oliver Klee
Tested-by: Oliver Klee
[BUGFIX] Tx_Phpunit_Service_TestFinderTest throws errors

Class Tx_Phpunit_Service_TestFinderTest throws errors if both directories
are available tests/ and typo3_src/tests/.

Change-Id: I32f274ae7cd94c0dc3eec731fbd2a1ccde347dc7
Resolves: #50216
Reviewed-on: https://review.typo3.org/22439
Reviewed-by: Oliver Klee
Tested-by: Oliver Klee
[TASK] Make test runner class files side-effect free

The test runner class files currently also include the code required to
run the tests. This is discouraged in the TYPO3 Core coding guidelines,
therefore this code is now moved into separate files.

Change-Id: I7899a653e3f4a4b086feb12f8b6c1ad30a6394af
Resolves: #50215
Reviewed-on: https://review.typo3.org/22441
Reviewed-by: Oliver Klee
Tested-by: Oliver Klee