Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
P
Production Test Suite - base
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Production Test Suite - base
Commits
d4f30392
Commit
d4f30392
authored
May 30, 2011
by
Juan David González Cobas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tps: make read_config read everything
parent
a30a38c4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
8 deletions
+12
-8
tps.py
tps.py
+12
-8
No files found.
tps.py
View file @
d4f30392
...
...
@@ -11,7 +11,7 @@ import datetime
import
random
import
warnings
from
ConfigParser
import
ConfigParser
from
ConfigParser
import
ConfigParser
,
NoOptionError
from
optparse
import
OptionParser
from
sha
import
sha
as
sha160
from
tpsexcept
import
*
...
...
@@ -44,6 +44,7 @@ class Suite(object):
self
.
config
=
default_config_file
self
.
log_pattern
=
default_log_pattern
self
.
log_name
=
default_log_name
self
.
read_config
(
self
.
config
)
def
missing
(
self
):
"""report missing fields before suite run"""
...
...
@@ -63,13 +64,16 @@ class Suite(object):
raise
TpsCritical
(
errmsg
)
config
=
ConfigParser
(
cfg
)
self
.
board
=
config
.
get
(
'global'
,
'board'
)
self
.
serial
=
config
.
get
(
'global'
,
'serial'
)
self
.
test_path
=
config
.
get
(
'global'
,
'test_path'
)
self
.
log_path
=
config
.
get
(
'global'
,
'log_path'
)
self
.
sequence
=
config
.
get
(
'global'
,
'sequence'
)
self
.
repeat
=
config
.
get
(
'global'
,
'repeat'
)
self
.
randomize
=
config
.
get
(
'global'
,
'randomize'
)
try
:
self
.
board
=
config
.
get
(
'global'
,
'board'
)
self
.
serial
=
config
.
get
(
'global'
,
'serial'
)
self
.
test_path
=
config
.
get
(
'global'
,
'test_path'
)
self
.
log_path
=
config
.
get
(
'global'
,
'log_path'
)
self
.
sequence
=
config
.
get
(
'global'
,
'sequence'
)
self
.
repeat
=
config
.
get
(
'global'
,
'repeat'
)
self
.
randomize
=
config
.
get
(
'global'
,
'randomize'
)
except
NoOptionError
:
pass
def
save
(
self
):
config
=
ConfigParser
()
...
...
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