blob: 7fa4d2149e6be32f533c7778c7153c77b6626df8 [file] [log] [blame]
This directory contains a simple core file for use in testing.
It was generated by running the following program with go1.9.0.
package main
func main() {
_ = *(*int)(nil)
The core file includes the executable by reference using an absolute
path. The executable was at /tmp/test, so that path is reproduced
here so the core dump reader can find the executable using this
testdata directory as the base directory.
core1.10 is produced in the same way, except using go1.10.0.
core1.11 is produced in the same way, except using go1.11.0.
steps for subsequent versions:
mkdir /tmp/coretest
rm -fr /tmp/coretest/* # in case there's old junk there
cp coretest/test.go /tmp/coretest
cd /tmp/coretest
go build test.go
GOTRACEBACK=crash ./test
zip /tmp/coretest/core /tmp/coretest/test // use your version number
Then move the to this directory.
Add a new test to TestVersions in ../gocore_test.go.
## runtimetype
This directory also contains the source code to generate the runtimetype core,
which is used to test getting runtime type for a interface.
steps for generate runtimetype core:
cd testdata/runtimetype
go build -o runtimetype .
ulimit -c unlimited
GOTRACEBACK=crash ./runtimetype
zip runtimetype core