test_doctests

./lib/python/pygrass/rpc – test_doctests

Test failed

Testtest_doctests
Testsuite./lib/python/pygrass/rpc
Test file./lib/python/pygrass/rpc/testsuite/test_doctests.py
StatusFAILED
Return code1
Number of tests4
Successful tests2
Failed tests2
Percent successful50%
Test duration0:00:01.912335

Supplementary files

Standard error output (stderr)

/usr/lib/python2.7/dist-packages/numpy/core/__init__.py:6: DeprecationWarning: CObject type is not supported in 3.x. Please use capsule objects instead.
  from . import multiarray
/usr/lib/python2.7/dist-packages/numpy/core/__init__.py:7: DeprecationWarning: CObject type is not supported in 3.x. Please use capsule objects instead.
  from . import umath
etc/python/grass/pygrass/raster/history.py:12: DeprecationWarning: Overriding __eq__ blocks inheritance of __hash__ in 3.x
  class History(object):
/usr/lib/python2.7/xml/etree/ElementTree.py:1627: DeprecationWarning: This method of XMLParser is deprecated.  Define doctype() method on the TreeBuilder target.
  DeprecationWarning,
Building topology for vector map <data_provider_vector_map@__lib_python_pygrass_rpc_test_doctests>...
Registering primitives...

21 primitives registered
41 vertices registered
Building areas...
0..4..9..14..19..23..28..33..38..42..47..52..57..61..66..71..76..80..85..90..95..100
4 areas built
2 isles built
Attaching islands...
50..100
Attaching centroids...
4..9..14..19..23..28..33..38..42..47..52..57..61..66..71..76..80..85..90..95..100
Number of nodes: 15
Number of primitives: 21
Number of points: 3
Number of lines: 3
Number of boundaries: 11
Number of centroids: 4
Number of areas: 4
Number of isles: 2
F.Process Process-3:
Traceback (most recent call last):
  File "/usr/lib/python2.7/multiprocessing/process.py", line 258, in _bootstrap
    self.run()
  File "/usr/lib/python2.7/multiprocessing/process.py", line 114, in run
    self._target(*self._args, **self._kwargs)
  File "etc/python/grass/pygrass/rpc/__init__.py", line 230, in data_provider_server
    functions[data[0]](lock, conn, data)
  File "etc/python/grass/pygrass/rpc/__init__.py", line 106, in _get_vector_table_as_dict
    raise ValueError("Unable to find vector map <%s>"%(name))
ValueError: Unable to find vector map <no_map>
WARNING:root:Needed to restart the libgis server, caller: Server check thread
.Process Process-6:
Traceback (most recent call last):
  File "/usr/lib/python2.7/multiprocessing/process.py", line 258, in _bootstrap
F    self.run()
  File "/usr/lib/python2.7/multiprocessing/process.py", line 114, in run
    self._target(*self._args, **self._kwargs)
  File "etc/python/grass/pygrass/rpc/base.py", line 40, in dummy_server
    raise Exception("Server process intentionally killed by exception")
Exception: Server process intentionally killed by exception

======================================================================
FAIL: get_raster_image_as_np (grass.pygrass.rpc.DataProvider)
Doctest: grass.pygrass.rpc.DataProvider.get_raster_image_as_np
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python2.7/doctest.py", line 2226, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for grass.pygrass.rpc.DataProvider.get_raster_image_as_np
  File "etc/python/grass/pygrass/rpc/__init__.py", line 253, in get_raster_image_as_np

----------------------------------------------------------------------
File "etc/python/grass/pygrass/rpc/__init__.py", line 289, in grass.pygrass.rpc.DataProvider.get_raster_image_as_np
Failed example:
    ret = provider.get_raster_image_as_np(name=test_raster_name,
                                          extent=extent)
Exception raised:
    Traceback (most recent call last):
      File "/usr/lib/python2.7/doctest.py", line 1315, in __run
        compileflags, 1) in test.globs
      File "<doctest grass.pygrass.rpc.DataProvider.get_raster_image_as_np[14]>", line 2, in <module>
        extent=extent)
      File "etc/python/grass/pygrass/rpc/__init__.py", line 299, in get_raster_image_as_np
        name, mapset, extent, color])
    IOError: [Errno 9] Bad file descriptor
----------------------------------------------------------------------
File "etc/python/grass/pygrass/rpc/__init__.py", line 291, in grass.pygrass.rpc.DataProvider.get_raster_image_as_np
Failed example:
    len(ret)
Expected:
    12
Got:
    16


======================================================================
FAIL: RPCServerBase (grass.pygrass.rpc.base)
Doctest: grass.pygrass.rpc.base.RPCServerBase
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python2.7/doctest.py", line 2226, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for grass.pygrass.rpc.base.RPCServerBase
  File "etc/python/grass/pygrass/rpc/base.py", line 43, in RPCServerBase

----------------------------------------------------------------------
File "etc/python/grass/pygrass/rpc/base.py", line 59, in grass.pygrass.rpc.base.RPCServerBase
Failed example:
    provider.is_server_alive()
Expected:
    False
Got:
    True


----------------------------------------------------------------------
Ran 4 tests in 0.823s
FAILED (failures=2)