~saviq/ubuntu-ui-toolkit/suru-switch

« back to all changes in this revision

Viewing changes to tests/qmlapicheck.py

  • Committer: CI bot
  • Author(s): Christian Dywan
  • Date: 2014-03-04 13:01:20 UTC
  • mfrom: (762.1.14 uut.qmlapicheckverbose)
  • Revision ID: ps-jenkins@lists.canonical.com-20140304130120-6z7wfu2atib45rkp
The wrapper is intended to make API test more visible in the output regardless of failure or success.
A semi-related fix increases coverage so that UbuntuTestCase and Layouts are also checked. 

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/usr/bin/env python
 
1
#!/usr/bin/env python3
2
2
# -*- coding: utf-8 -*-
3
3
#
4
4
# Copyright 2013 Canonical Ltd.
65
65
        fileinput.nextfile()
66
66
 
67
67
inputfiles.sort()
68
 
for line in fileinput.input(inputfiles):
 
68
 
 
69
hook = fileinput.hook_encoded('utf-8')
 
70
for line in fileinput.input(inputfiles, openhook=hook):
69
71
    # New file
70
72
    if fileinput.isfirstline():
71
73
        in_block = 0