Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@localhost.localdomain>2008-08-12 14:24:20 (GMT)
committer Marco Pesenti Gritti <marco@localhost.localdomain>2008-08-12 14:24:20 (GMT)
commit7cdf8e9e825477aabf0b94df33f259e78280e7b7 (patch)
tree167a4162f54eeaa5b9e46688b995684ee3985a8e /scripts
parent50c8d2b016477ba168fa3646639c3dfc0a1d8bc8 (diff)
Fix check ui error handling.
Diffstat (limited to 'scripts')
-rw-r--r--scripts/check.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/scripts/check.py b/scripts/check.py
index 4d0310b..f665e66 100644
--- a/scripts/check.py
+++ b/scripts/check.py
@@ -40,14 +40,11 @@ class UICheck(object):
shell_process = subprocess.Popen(args)
def _ui_check_exit_cb(self, pid, condition):
- self.exit_code = os.WEXITSTATUS(condition)
+ self._exit_code = os.WEXITSTATUS(condition)
self._mainloop.quit()
def _ui_check_read_cb(self, fd, condition):
- f = os.fdopen(fd, 'r')
- print f.read()
- f.close()
-
+ sys.stdout.write(os.read(fd, 1024))
return True
def _start_ui_check_cb(self):
@@ -133,15 +130,18 @@ class cmd_check(Command):
print 'Done.'
def run(self, config, options, args):
+ result = 0
xvfb_pid = self.start_xvfb()
try:
if options.type == 'pylint':
self.check_pylint(config)
if options.type == 'ui':
- self.check_ui(config)
+ result = self.check_ui(config)
finally:
if xvfb_pid:
os.kill(xvfb_pid, signal.SIGTERM)
+ return result
+
register_command(cmd_check)