Skip to content

Commit

Permalink
Fix coverage config and master_len test
Browse files Browse the repository at this point in the history
Something has changed in pytest (or something to do with the test
suite). All of a sudden some warnings are getting suppressed within a
function despite setup_module supposedly activating warnings always.
  • Loading branch information
waveform80 committed Mar 5, 2018
1 parent 178b1b1 commit b40dcda
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions coverage.cfg
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
[run]
branch = True
include = compoundfiles/*
;omit = */bar.py,*/baz.py
source = compoundfiles

[report]
include = compoundfiles/*
ignore_errors = True
show_missing = True
exclude_lines =
Expand Down
4 changes: 2 additions & 2 deletions tests/test_function.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

DirEntry = namedtuple('DirEntry', ('name', 'isfile', 'size'))

def setup_module(module):
def setup_function(fn):
warnings.simplefilter('always')

def verify_contents(doc, contents):
Expand Down Expand Up @@ -461,7 +461,7 @@ def test_strange_master_ext():
def test_invalid_master_loop():
with pytest.raises(cf.CompoundFileMasterLoopError):
# Same as strange_master_ext.dat but with DIFAT extension sector filled
# and terminated with a self, test_contents=False-reference
# and terminated with a self-reference
doc = cf.CompoundFileReader('tests/invalid_master_loop.dat')

def test_invalid_master_len():
Expand Down

0 comments on commit b40dcda

Please sign in to comment.