Selected Go-internal packages factored out from the standard library
This is hard forked from github.com/rogpeppe/testscript to allow the gh maintainers to explore the use of testscript in gh, while providing the flexibility for us to share modifications and extensions. It is not intended to be a long-term maintained fork and you should not rely on it.
If we determine it is a good fit for the project, we will decide what to do next based on how our needs align with the preferences of the maintainers of rogpeppe/testscript.
This repository factors out an opinionated selection of internal packages and functionality from the Go standard
library. Currently this consists mostly of packages and testing code from within the Go tool implementation.
The upstream repo is primarily maintained by long-time
Go contributors who are also currently
maintaining CUE (which is primarily written in Go
and which relies upon several of the packages here).
Contributions are welcome, but please open an issue for discussion first.
Included are the following:
Note that most users of txtar should use https://pkg.go.dev/golang.org/x/tools/txtar instead.
Our package will be replaced by it once https://github.com/golang/go/issues/59264 is fixed.
The most popular package here is the testscript package:
go command.go test, including coverage support.A nice introduction to using testscripts is this blog post series.
Both testscript and txtar were originally created
by Russ Cox.