Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
4ea578c8
Commit
4ea578c8
authored
May 29, 2011
by
Denis Bilenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
testrunner.py: delete skipped test cases (previously there were logged as TIMEOUT)
parent
7bf6cdd6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
0 deletions
+21
-0
greentest/testrunner.py
greentest/testrunner.py
+21
-0
No files found.
greentest/testrunner.py
View file @
4ea578c8
...
@@ -89,6 +89,23 @@ def store_record(database_path, table, dictionary, _added_colums_per_db={}):
...
@@ -89,6 +89,23 @@ def store_record(database_path, table, dictionary, _added_colums_per_db={}):
return
cursor
.
lastrowid
return
cursor
.
lastrowid
def
delete_record
(
database_path
,
table
,
dictionary
,
_added_colums_per_db
=
{}):
if
sqlite3
is
None
:
return
keys
=
dictionary
.
keys
()
conn
=
sqlite3
.
connect
(
database_path
)
print
'deleting %s from database'
%
(
dictionary
,
)
sql
=
'delete from %s where %s'
%
(
table
,
' AND '
.
join
(
'%s=:%s'
%
(
key
,
key
)
for
key
in
keys
))
cursor
=
conn
.
cursor
()
try
:
cursor
.
execute
(
sql
,
dictionary
)
except
sqlite3
.
Error
:
print
'sql=%r
\
n
dictionary=%r'
%
(
sql
,
dictionary
)
raise
conn
.
commit
()
return
cursor
.
lastrowid
class
DatabaseTestResult
(
_TextTestResult
):
class
DatabaseTestResult
(
_TextTestResult
):
separator1
=
'='
*
70
separator1
=
'='
*
70
separator2
=
'-'
*
70
separator2
=
'-'
*
70
...
@@ -108,6 +125,10 @@ class DatabaseTestResult(_TextTestResult):
...
@@ -108,6 +125,10 @@ class DatabaseTestResult(_TextTestResult):
from
time
import
time
from
time
import
time
self
.
time
=
time
()
self
.
time
=
time
()
def
addSkip
(
self
,
test
,
reason
):
delete_record
(
self
.
database_path
,
'testcase'
,
self
.
params
)
return
super
(
DatabaseTestResult
,
self
).
addSkip
(
test
,
reason
)
def
_store_result
(
self
,
test
,
result
):
def
_store_result
(
self
,
test
,
result
):
self
.
params
[
'result'
]
=
result
self
.
params
[
'result'
]
=
result
from
time
import
time
from
time
import
time
...
...
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