Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Trac #28756: py3: fix doctests with gurobi
With sage 9.0.beta6 and gurobi, we get 17 failing doctests due to str vs bytes (`TypeError: expected bytes, str found`), char vs str, and the change of behavior of zip between py2 and py3 (`TypeError: object of type 'zip' has no len()`). Some problems were fixed in #28206, but it was apparently not enough. Try: {{{ sage -t --long --optional=sage,optional,external src/sage/numerical/linear_functions.pyx src/sage/numerical/linear_tensor.py src/sage/numerical/linear_tensor_constraints.py src/sage/numerical/linear_tensor_element.pyx src/sage/numerical/mip.pyx src/sage/numerical/backends/gurobi_backend.pyx }}} which gives {{{ ---------------------------------------------------------------------- sage -t src/sage/numerical/linear_functions.pyx # 29 doctests failed sage -t src/sage/numerical/linear_tensor.py # 20 doctests failed sage -t src/sage/numerical/linear_tensor_constraints.py # 28 doctests failed sage -t src/sage/numerical/linear_tensor_element.pyx # 23 doctests failed sage -t src/sage/numerical/mip.pyx # 4 doctests failed sage -t src/sage/numerical/backends/gurobi_backend.pyx # 17 doctests failed ---------------------------------------------------------------------- }}} We also fix some compilation warnings. URL: https://trac.sagemath.org/28756 Reported by: dcoudert Ticket author(s): David Coudert Reviewer(s): Sébastien Labbé
- Loading branch information