Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
75f2364e
Commit
75f2364e
authored
Sep 02, 2007
by
meus
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixing testrunner and cc report to look nicer
parent
70ff3b26
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
16 additions
and
36 deletions
+16
-36
RelationTest.php
models/RelationTest.php
+9
-0
RelationTestChild.php
models/RelationTestChild.php
+0
-10
cc.php
tests/cc.php
+6
-25
run.php
tests/run.php
+1
-1
No files found.
models/RelationTest.php
View file @
75f2364e
...
...
@@ -8,3 +8,12 @@ class RelationTest extends Doctrine_Record
}
}
class
RelationTestChild
extends
RelationTest
{
public
function
setUp
()
{
$this
->
hasOne
(
'RelationTest as Parent'
,
'RelationTestChild.child_id'
);
$this
->
ownsMany
(
'RelationTestChild as Children'
,
'RelationTestChild.child_id'
);
}
}
models/RelationTestChild.php
deleted
100644 → 0
View file @
70ff3b26
<?php
class
RelationTestChild
extends
RelationTest
{
public
function
setUp
()
{
$this
->
hasOne
(
'RelationTest as Parent'
,
'RelationTestChild.child_id'
);
$this
->
ownsMany
(
'RelationTestChild as Children'
,
'RelationTestChild.child_id'
);
}
}
tests/cc.php
View file @
75f2364e
...
...
@@ -32,28 +32,7 @@ $reporter = new Doctrine_Coverage_Report("coverage.txt");
.red
{
background
:
red
;}
.orange
{
background
:
#f90
;}
dl
.table-display
{
margin
:
2em
0
;
padding
:
0
;
font-family
:
georgia
,
times
,
serif
;
}
.table-display
dt
{
float
:
left
;
margin
:
0
0
0
0
;
padding
:
0
.5em
0
.5em
;
}
/* commented backslash hack for mac-ie5 \*/
dt
{
clear
:
both
;
}
/* end hack */
.table-display
dd
{
float
:
left
;
margin
:
0
0
0
0
;
}
</style>
</head>
<body>
...
...
@@ -136,10 +115,10 @@ class Doctrine_Coverage_Report
}
$coveredLines
=
$this
->
coverage
[
$key
];
$fileArray
=
file
(
Doctrine
::
getPath
()
.
"/"
.
$fileName
);
$html
.=
'<
dl class="table-display"
>'
.
"
\n
"
;
$html
.=
'<
table
>'
.
"
\n
"
;
foreach
(
$fileArray
as
$num
=>
$line
){
$linenum
=
$num
+
1
;
$html
.=
'<
dt>'
.
$linenum
.
'</dt
>'
.
"
\n
"
;
$html
.=
'<
tr><td>'
.
$linenum
.
'</td
>'
.
"
\n
"
;
$class
=
"normal"
;
if
(
isset
(
$coveredLines
[
$linenum
])
&&
$coveredLines
[
$linenum
]
==
1
){
$class
=
"covered"
;
...
...
@@ -148,9 +127,11 @@ class Doctrine_Coverage_Report
}
else
if
(
isset
(
$coveredLines
[
$linenum
])
&&
$coveredLines
[
$linenum
]
==
-
2
)
{
$class
=
"orange"
;
}
$html
.=
'<dd class="'
.
$class
.
'">'
.
htmlspecialchars
(
$line
)
.
'</dd>'
.
"
\n
"
;
$line
=
str_replace
(
" "
,
" "
,
htmlspecialchars
(
$line
));
$html
.=
'<td class="'
.
$class
.
'">'
.
$line
.
'</td></tr>'
.
"
\n
"
;
}
$html
.=
'</
dl
></div>'
;
$html
.=
'</
table
></div>'
;
echo
$html
;
}
...
...
tests/run.php
View file @
75f2364e
...
...
@@ -425,7 +425,7 @@ if (PHP_SAPI === "cli") {
$argv
=
$_SERVER
[
"argv"
];
$coverage
=
false
;
array_shift
(
$argv
);
if
(
isset
(
$argv
[
1
])
&&
$argv
[
1
]
==
"coverage"
){
if
(
isset
(
$argv
[
0
])
&&
$argv
[
0
]
==
"coverage"
){
array_shift
(
$argv
);
$coverage
=
true
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment