Permalink
Browse files

- Merge [894].

  • Loading branch information...
1 parent 8435081 commit 5b9b61884022f61f2856b4923ab90715bd2941a2 @sebastianbergmann committed Aug 2, 2007
@@ -150,19 +150,21 @@ public function storeCodeCoverage(PHPUnit_Framework_TestResult $result, $revisio
'INSERT INTO code_class
(code_file_id, code_class_name,
code_class_start_line, code_class_end_line,
- code_class_wmc)
- VALUES(:fileId, :className, :startLine, :endLine, 0);'
+ code_class_dit, code_class_wmc)
+ VALUES(:fileId, :className, :startLine, :endLine, :dit, 0);'
);
foreach ($classes as $class) {
$className = $class->getName();
$startLine = $class->getStartLine();
$endLine = $class->getEndLine();
+ $dit = PHPUnit_Util_Class::getDIT( $className );
$stmt->bindParam(':fileId', $fileId, PDO::PARAM_INT);
$stmt->bindParam(':className', $className, PDO::PARAM_STR);
$stmt->bindParam(':startLine', $startLine, PDO::PARAM_INT);
$stmt->bindParam(':endLine', $endLine, PDO::PARAM_INT);
+ $stmt->bindParam(':dit', $dit, PDO::PARAM_INT);
$stmt->execute();
$classId = $this->dbh->lastInsertId();
@@ -79,6 +79,7 @@ CREATE TABLE IF NOT EXISTS code_class(
code_class_name CHAR(255),
code_class_start_line INTEGER UNSIGNED NOT NULL,
code_class_end_line INTEGER UNSIGNED NOT NULL,
+ code_class_dit INTEGER UNSIGNED NOT NULL,
code_class_wmc INTEGER UNSIGNED NOT NULL,
INDEX (code_file_id)
@@ -79,6 +79,7 @@ CREATE TABLE IF NOT EXISTS code_class(
code_class_name TEXT,
code_class_start_line INTEGER,
code_class_end_line INTEGER,
+ code_class_dit INTEGER,
code_class_wmc INTEGER
);

0 comments on commit 5b9b618

Please sign in to comment.