Skip to content

Commit ceb99b0

Browse files
authored
Remove test verbosity and add Readme Travis CI testing status icon
Default test verbosity to False to make it easier to spot the test failures. Partially fixes #54.
1 parent 8b34fc9 commit ceb99b0

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
# PyShp
2+
3+
This library reads and writes ESRI Shapefiles in pure Python.
4+
5+
[![Build Status](https://travis-ci.org/GeospatialPython/pyshp.svg?branch=master)](https://travis-ci.org/GeospatialPython/pyshp)
6+
17
## Contents
28

39
[Overview](#overview)

shapefile.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1245,8 +1245,12 @@ def __fieldNorm(self, fieldName):
12451245
def test(**kwargs):
12461246
import doctest
12471247
doctest.NORMALIZE_WHITESPACE = 1
1248-
verbosity = kwargs.get('verbose', 1)
1248+
verbosity = kwargs.get('verbose', 0)
1249+
if verbosity == 0:
1250+
print('Running doctests...')
12491251
failure_count, test_count = doctest.testfile("README.md", verbose=verbosity)
1252+
if verbosity == 0 and failure_count == 0:
1253+
print('All test passed successfully')
12501254
return failure_count
12511255

12521256
if __name__ == "__main__":

0 commit comments

Comments
 (0)