Пример #1
0
 public function testIsTestFile()
 {
     $this->guy->createTestFolderTree($this->tmpPath1);
     $this->assertTrue($this->guy->isTestFolderTree($this->tmpPath1));
     // real tests
     $this->assertTrue(TestRunner::isTestFile($this->tmpPath1 . DS . 'subFolder1' . DS . 'unit' . DS . 'funTest.php'));
     $this->assertTrue(TestRunner::isTestFile($this->tmpPath1 . DS . 'subFolder2' . DS . 'unit' . DS . 'boringTestCest.php'));
     $this->assertTrue(TestRunner::isTestFile($this->tmpPath1 . DS . 'subFolder2' . DS . 'unit' . DS . 'interestingTestCept.php'));
     // not real tests
     $this->assertFalse(TestRunner::isTestFile($this->tmpPath1 . DS . 'README.txt'));
     $this->assertFalse(TestRunner::isTestFile($this->tmpPath1 . DS . 'nonExistentFile.txt'));
 }