Showing 1 of 1 files from the diff.

@@ -21,6 +21,7 @@
Loading
21 21
22 22
"""
23 23
24 +
import contextlib
24 25
import cups
25 26
import logging
26 27
import os
@@ -189,14 +190,11 @@
Loading
189 190
                    "Failed to create title page with command: %s"
190 191
                    "(error %d)" % (pretty_print_cmdline(cmd), ret))
191 192
192 -
            pdfmerger = PdfFileMerger()
193 -
            with open(title_pdf, "rb") as file_:
194 -
                pdfmerger.append(file_)
195 -
            with open(source_pdf, "rb") as file_:
196 -
                pdfmerger.append(file_)
197 -
            result = os.path.join(directory, "document.pdf")
198 -
            with open(result, "wb") as file_:
199 -
                pdfmerger.write(file_)
193 +
            with contextlib.closing(PdfFileMerger()) as pdfmerger:
194 +
                pdfmerger.append(title_pdf)
195 +
                pdfmerger.append(source_pdf)
196 +
                result = os.path.join(directory, "document.pdf")
197 +
                pdfmerger.write(result)
200 198
201 199
            try:
202 200
                printer_connection = cups.Connection()
Files Coverage
cms 73.81%
cmscommon 61.03%
cmscontrib 45.86%
cmsranking 60.73%
cmstaskenv 0.00%
Project Totals (232 files) 63.60%
1540.1
TRAVIS_OS_NAME=linux
3.8=unittests.8
unittests
1540.2
3.6=unittests.6
TRAVIS_OS_NAME=linux
unittests
1540.1
TRAVIS_OS_NAME=linux
3.8=functionaltests.8
functionaltests
1540.2
3.6=functionaltests.6
TRAVIS_OS_NAME=linux
functionaltests
1540.2
3.6=unittests.6
TRAVIS_OS_NAME=linux
unittests
1540.1
TRAVIS_OS_NAME=linux
3.8=unittests.8
unittests
1540.2
3.6=functionaltests.6
TRAVIS_OS_NAME=linux
functionaltests
1540.1
TRAVIS_OS_NAME=linux
3.8=functionaltests.8
functionaltests

No yaml found.

Create your codecov.yml to customize your Codecov experience

Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading