Files
upstream-golang-migrate/testing/testing_test.go
upstream-mirror 9f3bffc2d3
Some checks failed
CI / test (1.26.x) (push) Failing after 5s
CI / Check coverage (push) Has been skipped
CI / lint (push) Failing after 41s
CI / test (1.25.x) (push) Failing after 54s
CI / Release a new version (push) Has been skipped
snapshot of https://github.com/golang-migrate/migrate.git (master, 2026-09-15; blobs > 131072B omitted)
2026-09-15 21:52:57 +05:00

23 lines
475 B
Go

package testing
import (
"testing"
)
func ExampleParallelTest() {
t := &testing.T{} // Should actually be used in a Test
var isReady = func(i Instance) bool {
// Return true if Instance is ready to run tests.
// Don't block here though.
return true
}
// t is *testing.T coming from parent Test(t *testing.T)
ParallelTest(t, []Version{{Image: "docker_image:9.6"}}, isReady,
func(t *testing.T, i Instance) {
// Run your test/s ...
t.Fatal("...")
})
}