diff options
author | njsmith <njs@pobox.com> | 2013-05-01 06:56:53 -0700 |
---|---|---|
committer | njsmith <njs@pobox.com> | 2013-05-01 06:56:53 -0700 |
commit | 5808c8a3f67fd03de0a5b5c2c95613a230b6b3c1 (patch) | |
tree | 2966c8a6f4a5a0bd2e7b12d3c9b2b5d26e8d3f67 /doc/sphinxext/numpydoc/tests/test_docscrape.py | |
parent | a8805f65d25e7268a722da47d490167d99e1559f (diff) | |
parent | 54524cdce7806e50813688b95c89b039a32f0a7c (diff) | |
download | numpy-5808c8a3f67fd03de0a5b5c2c95613a230b6b3c1.tar.gz |
Merge pull request #3296 from pv/fix-sphinxext
BUG: sphinxext: fix sphinx extensions broken recently
Diffstat (limited to 'doc/sphinxext/numpydoc/tests/test_docscrape.py')
-rw-r--r-- | doc/sphinxext/numpydoc/tests/test_docscrape.py | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/doc/sphinxext/numpydoc/tests/test_docscrape.py b/doc/sphinxext/numpydoc/tests/test_docscrape.py index 45bedc88a..7b7375a5a 100644 --- a/doc/sphinxext/numpydoc/tests/test_docscrape.py +++ b/doc/sphinxext/numpydoc/tests/test_docscrape.py @@ -136,7 +136,7 @@ def test_parameters(): assert_equal([n for n,_,_ in doc['Parameters']], ['mean','cov','shape']) arg, arg_type, desc = doc['Parameters'][1] - assert_equal(arg_type, '(N,N) ndarray') + assert_equal(arg_type, '(N, N) ndarray') assert desc[0].startswith('Covariance matrix') assert doc['Parameters'][0][-1][-2] == ' (1+2+3)/3' @@ -176,8 +176,8 @@ def test_index(): def non_blank_line_by_line_compare(a,b): a = textwrap.dedent(a) b = textwrap.dedent(b) - a = [l for l in a.split('\n') if l.strip()] - b = [l for l in b.split('\n') if l.strip()] + a = [l.rstrip() for l in a.split('\n') if l.strip()] + b = [l.rstrip() for l in b.split('\n') if l.strip()] for n,line in enumerate(a): if not line == b[n]: raise AssertionError("Lines %s of a and b differ: " @@ -313,7 +313,7 @@ of the one-dimensional normal distribution to higher dimensions. (1+2+3)/3 - **cov** : (N,N) ndarray + **cov** : (N, N) ndarray Covariance matrix of the distribution. @@ -563,10 +563,7 @@ def test_unicode(): """) assert isinstance(doc['Summary'][0], str) - if sys.version_info[0] >= 3: - assert doc['Summary'][0] == sixu('öäöäöäöäöåååå') - else: - assert doc['Summary'][0] == sixu('öäöäöäöäöåååå').encode('utf-8') + assert doc['Summary'][0] == 'öäöäöäöäöåååå' def test_plot_examples(): cfg = dict(use_plots=True) |