瀏覽代碼

gunittest: Fix stdout used instead of stderr (#1707)

Changes in 51fc3d6276a4f7468e3add3e535f99ff5f21ee91 (#1539) introduced a bug where stdout
was used always, so stderr was never visible in test results.
This uses the correct local variable, not the stdout from outer scope.
Vaclav Petras 3 年之前
父節點
當前提交
984d11afb2
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      python/grass/gunittest/invoker.py

+ 1 - 1
python/grass/gunittest/invoker.py

@@ -225,7 +225,7 @@ class GrassTestFilesInvoker(object):
             """
             for encoding in encodings:
                 try:
-                    return decode(stdout, encoding=encoding)
+                    return decode(data, encoding=encoding)
                 except UnicodeError:
                     pass
             if isinstance(data, bytes):