public static function run(): int {
            $startOfRun = microtime(true);
            $testDurationInMicroseconds = 0;

            $reporter = new ConsoleReporter;
            $reporter->setMaxEntries(static::$numberOfTest);
            $reporter->doNotClearProgress();
            $reporter->displaySeverityWithIcons();
            $reporter->setProgressBarSize(36);
            
            $currentDescriptionIndex = 1;
            $lastDescription = false;
            $lastTest = false;

            $completedTests = 0;
            $failedTests = 0;

            foreach( static::$tests as $description => $tests ) {
                if( static::allowedToReportDescription() === true ) {
                    $reporter->info("Running tests for \"$description\"");
                }

                $lastDescription = $currentDescriptionIndex === count(static::$tests);

                $currentTestIndex = 1;

                foreach( $tests as $expectedBehaviorString => $callableTest ) {
                    $startOfTest = microtime(true);
                    
                    try {
                        $lastTest = $currentTestIndex === count($tests);

                        $currentTestIndex++;

                        call_user_func($callableTest);

                        if( static::$reportLevel === ReportLevel::DETAILED ) {
                            $reporter->success('"it ' . $expectedBehaviorString . '" completed');
                        }

                        $completedTests++;
                    }
                    catch( TestFailedException $exception ) {
                        if( static::allowedToReportTestFailed() === true ) {
                            $reporter->error('"it ' . $expectedBehaviorString . '" failed');
                            $reporter->error($exception->getMessage());
                        }

                        $failedTests++;
                    }
                    finally {
                        $endOfTest = microtime(true);
                        $testDurationInMicroseconds += $endOfTest - $startOfTest;

                        if( $lastDescription === true && $lastTest === true ) {
                            $endOfRun = microtime(true);
                            $totalRunTimeInMicroseconds = $endOfRun - $startOfRun;
                            $extraRunTimeInMicoseconds  = round($totalRunTimeInMicroseconds - $testDurationInMicroseconds, 4);
                            $testDurationInMicroseconds = round($testDurationInMicroseconds, 4);

                            $reporter->debug("$completedTests tests completed, $failedTests tests failed");                            

                            if( static::allowedToReportElapsedTime() === true ) {
                                $reporter->debug("tests ran in $testDurationInMicroseconds sec. (+$extraRunTimeInMicoseconds sec.)");       
                            }
                        }

                        $reporter->report();
                        $reporter->advance();
                    }
                }

                $currentDescriptionIndex++;
            }

            if( $failedTests > 0 ) {
                return 1;
            }
            else {
                return 0;
            }
        }