Skip to content

Commit

Permalink
.coverage file is now saved again (nose-devs#439). Also bump to 1.1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
kumar303 committed Jul 30, 2011
1 parent e5a58e6 commit 136d969
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 6 deletions.
7 changes: 6 additions & 1 deletion CHANGELOG
@@ -1,3 +1,8 @@
1.1.2

- Fixed regression where the .coverage file was not saved (#439).
Patch by Timothée Peignier.

1.1.1

- Fixed missing nose.sphinx module in source distribution (#436).
Expand All @@ -11,7 +16,7 @@
- Lots of improvements to the attrib plugin by Bobby Impollonia (#412, #411,
#324 and #381)
- Code coverage plugin now uses native HTML generation when coverage 3 is
installed (#264). Thanks to Timothee Peignier for the patch.
installed (#264). Thanks to Timothée Peignier for the patch.
- Xunit plugin now shows test run time in fractions of a second (#317)
- @attr (from nose.plugins.attrib) can now be used as a class decorator (#292)
- Fixes Xunit plugin to handle non-UTF8 characters (#395)
Expand Down
2 changes: 1 addition & 1 deletion doc/conf.py
Expand Up @@ -57,7 +57,7 @@
# The short X.Y version.
version = '1.1'
# The full version, including alpha/beta/rc tags.
release = '1.1.1'
release = '1.1.2'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
Expand Up @@ -14,12 +14,16 @@ code coverage, the coverage plugin supports basic HTML coverage output.
>>> import os
>>> support = os.path.join(os.path.dirname(__file__), 'support')
>>> cover_html_dir = os.path.join(support, 'cover')
>>> cover_file = os.path.join(os.getcwd(), '.coverage')
>>> if os.path.exists(cover_file):
... os.unlink(cover_file)
...
The console coverage output is printed, as normal.

>>> cover_html_dir = os.path.join(support, 'cover')
>>> from nose.plugins.cover import Coverage
>>> cover_html_dir = os.path.join(support, 'cover')
>>> run(argv=[__file__, '-v', '--with-coverage', '--cover-package=blah',
... '--cover-html', '--cover-html-dir=' + cover_html_dir,
... support, ],
Expand All @@ -43,6 +47,8 @@ covered and which are not. There is an example of this HTML output in the
`coverage.py`_ docs.

.. hide this from the actual documentation:
>>> os.path.exists(cover_file)
True
>>> os.path.exists(os.path.join(cover_html_dir, 'index.html'))
True
>>> os.path.exists(os.path.join(cover_html_dir, 'blah.html'))
Expand Down
2 changes: 1 addition & 1 deletion nose/__init__.py
Expand Up @@ -4,7 +4,7 @@
from nose.tools import with_setup

__author__ = 'Jason Pellerin'
__versioninfo__ = (1, 1, 1)
__versioninfo__ = (1, 1, 2)
__version__ = '.'.join(map(str, __versioninfo__))

__all__ = [
Expand Down
1 change: 1 addition & 0 deletions nose/plugins/cover.py
Expand Up @@ -164,6 +164,7 @@ def report(self, stream):
"""
log.debug("Coverage report")
self.coverInstance.stop()
self.coverInstance.save()
modules = [ module
for name, module in sys.modules.items()
if self.wantModuleCoverage(name, module) ]
Expand Down
2 changes: 1 addition & 1 deletion nosetests.1
Expand Up @@ -476,5 +476,5 @@ jpellerin+nose@gmail.com
.SH COPYRIGHT
LGPL

.\" Generated by docutils manpage writer on 2011-07-27 17:21.
.\" Generated by docutils manpage writer on 2011-07-30 18:43.
.\"
2 changes: 1 addition & 1 deletion setup.py
@@ -1,7 +1,7 @@
import sys
import os

VERSION = '1.1.1'
VERSION = '1.1.2'
py_vers_tag = '-%s.%s' % sys.version_info[:2]

test_dirs = ['functional_tests', 'unit_tests', os.path.join('doc','doc_tests'), 'nose']
Expand Down

0 comments on commit 136d969

Please sign in to comment.