Opened 3 years ago

Closed 3 years ago

#27165 closed enhancement (fixed)

py3: fix doctests in c_graph.pyx

Reported by: dcoudert Owned by:
Priority: major Milestone: sage-8.7
Component: graph theory Keywords: py3, graph
Cc: Merged in:
Authors: David Coudert Reviewers: Vincent Klein
Report Upstream: N/A Work issues:
Branch: db731ef (Commits, GitHub, GitLab) Commit: db731ef4cf7df65c63e8bfdc210688c3c82d1d96
Dependencies: Stopgaps:

Status badges


One doctest is fixed replacing a call to .edges() by a call to .edges_incident(1)

For the doctest of depth_first_search, we distinguish py2 and py3. The ordering in py3 is unstable, so we use ....

For the doctest of breadth_first_search, we change the graph to ensure that there is a unique solution for the last visited vertex. So the same doctest is valid for py2 and py3.

Change History (3)

comment:1 Changed 3 years ago by dcoudert

  • Branch set to public/27165_c_graph
  • Commit set to db731ef4cf7df65c63e8bfdc210688c3c82d1d96
  • Status changed from new to needs_review

If you have better solutions in mind, please share them.

New commits:

db731eftrac #27165: fix doctests

comment:2 Changed 3 years ago by vklein

  • Reviewers set to Vincent Klein
  • Status changed from needs_review to positive_review

Looks good to me.

comment:3 Changed 3 years ago by vbraun

  • Branch changed from public/27165_c_graph to db731ef4cf7df65c63e8bfdc210688c3c82d1d96
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.