Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Cleanup.

  • Loading branch information...
commit 865413a6fbb7500608e1a1f134273381a38f0c54 1 parent 1226be2
@sebastianbergmann authored
Showing with 5 additions and 10 deletions.
  1. +5 −10 PHPUnit/Util/Metrics/File.php
View
15 PHPUnit/Util/Metrics/File.php
@@ -96,7 +96,10 @@ protected function __construct($filename, &$codeCoverage = array())
$this->filename = $filename;
- $this->countLines();
+ foreach (PHPUnit_Util_File::countLines($this->filename) as $name => $value) {
+ $this->$name = $value;
+ }
+
$this->setCoverage($codeCoverage);
foreach (PHPUnit_Util_File::getClassesInFile($filename) as $className => $class) {
@@ -219,7 +222,7 @@ public function getLines()
*/
public function getTokens()
{
- return token_get_all(file_get_contents($this->filename));
+ return token_get_all(file_get_contents($this->filename));
}
/**
@@ -301,13 +304,5 @@ protected function calculateCodeCoverage(&$codeCoverage)
$this->locExecutable = $statistics['locExecutable'];
$this->locExecuted = $statistics['locExecuted'];
}
-
- /**
- */
- protected function countLines()
- {
- foreach (PHPUnit_Util_File::countLines($this->filename) as $name => $value)
- $this->$name = $value;
- }
}
?>
Please sign in to comment.
Something went wrong with that request. Please try again.