x/pkgsite: examples not rendered according to the testing documentation; includes unwanted code #43658
Labels
Milestone
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What is the URL of the page with the issue?
https://pkg.go.dev/gonum.org/v1/gonum/graph/community#example-Profile-Simple
What is your user agent?
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:84.0) Gecko/20100101 Firefox/84.0
Screenshot
What did you do?
Navigate to the linked example.
What did you expect to see?
According to the testing documentation
I expect to see just the body of the example as rendered on godoc.org since there is more than one example in the file.
What did you see instead?
Extraneous details also presented (and the imports mangled and helpful comments removed).
The parts included are used by the second example and so entirely unrelated to the first. The choice of including two examples in the file was specifically to prevent these details leaking to the reader since they do not help advance the documentation.
The text was updated successfully, but these errors were encountered: