mageekguy\atoum\runner::addTestsFromDirectory PHP Method

addTestsFromDirectory() public method

public addTestsFromDirectory ( $directory )
    public function addTestsFromDirectory($directory)
    {
        try {
            $paths = array();
            foreach (new \recursiveIteratorIterator($this->testDirectoryIterator->getIterator($directory)) as $path) {
                $paths[] = $path;
            }
        } catch (\UnexpectedValueException $exception) {
            throw new exceptions\runtime('Unable to read test directory \'' . $directory . '\'');
        }
        natcasesort($paths);
        foreach ($paths as $path) {
            $this->addTest($path);
        }
        return $this;
    }
runner