Release 0.0.10.
authorRobert Collins <robertc@robertcollins.net>
Thu, 7 Feb 2013 11:33:11 +0000 (00:33 +1300)
committerRobert Collins <robertc@robertcollins.net>
Thu, 7 Feb 2013 11:33:11 +0000 (00:33 +1300)
NEWS
README
configure.ac
python/subunit/__init__.py

diff --git a/NEWS b/NEWS
index 045760721056d68a83b3cf3baa6e60015d84966f..129f99b68415fdecd576535e941da45967fcaa75 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -5,6 +5,9 @@ subunit release notes
 NEXT (In development)
 ---------------------
 
+0.0.10
+------
+
 BUG FIXES
 ~~~~~~~~~
 
diff --git a/README b/README
index e3971957eb2f78b7e4815b49d414916d59ff8183..aab5faf46b541bfdfcf868b1fd9dc7e60c40c126 100644 (file)
--- a/README
+++ b/README
@@ -1,6 +1,6 @@
 
   subunit: A streaming protocol for test results
-  Copyright (C) 2005-2009 Robert Collins <robertc@robertcollins.net>
+  Copyright (C) 2005-2013 Robert Collins <robertc@robertcollins.net>
 
   Licensed under either the Apache License, Version 2.0 or the BSD 3-clause
   license at the users choice. A copy of both licenses are available in the
index cf21d554808bad1432979e411ea440a1d2e4ac9d..8c300ee82eca1936040f54f7d7697f97213b4538 100644 (file)
@@ -1,6 +1,6 @@
 m4_define([SUBUNIT_MAJOR_VERSION], [0])
 m4_define([SUBUNIT_MINOR_VERSION], [0])
-m4_define([SUBUNIT_MICRO_VERSION], [9])
+m4_define([SUBUNIT_MICRO_VERSION], [10])
 m4_define([SUBUNIT_VERSION],
 m4_defn([SUBUNIT_MAJOR_VERSION]).m4_defn([SUBUNIT_MINOR_VERSION]).m4_defn([SUBUNIT_MICRO_VERSION]))
 AC_PREREQ([2.59])
index f870904a5eaed3dda511770c5dbf459c84d00a72..77f4a821c1f0dcc7600cd4a190ee907a5625163c 100644 (file)
@@ -159,7 +159,7 @@ from subunit import chunked, details, iso8601, test_results
 # If the releaselevel is 'final', then the tarball will be major.minor.micro.
 # Otherwise it is major.minor.micro~$(revno).
 
-__version__ = (0, 0, 9, 'final', 0)
+__version__ = (0, 0, 10, 'final', 0)
 
 PROGRESS_SET = 0
 PROGRESS_CUR = 1
@@ -1301,14 +1301,17 @@ def _make_binary_on_windows(fileno):
 def _unwrap_text(stream):
     """Unwrap stream if it is a text stream to get the original buffer."""
     if sys.version_info > (3, 0):
+        unicode_type = str
+    else:
+        unicode_type = unicode
+    try:
+        # Read streams
+        if type(stream.read(0)) is unicode_type:
+            return stream.buffer
+    except (_UnsupportedOperation, IOError):
+        # Cannot read from the stream: try via writes
         try:
-            # Read streams
-            if type(stream.read(0)) is str:
-                return stream.buffer
-        except (_UnsupportedOperation, IOError):
-            # Cannot read from the stream: try via writes
-            try:
-                stream.write(_b(''))
-            except TypeError:
-                return stream.buffer
+            stream.write(_b(''))
+        except TypeError:
+            return stream.buffer
     return stream