(t *testing.T)
| 34 | } |
| 35 | |
| 36 | func TestCheckpoint_WaitComplete(t *testing.T) { |
| 37 | t.Parallel() |
| 38 | logger := testutil.Logger(t) |
| 39 | ctx := testutil.Context(t, testutil.WaitShort) |
| 40 | uut := newCheckpoint(logger) |
| 41 | err := xerrors.New("test") |
| 42 | errCh := make(chan error, 1) |
| 43 | go func() { |
| 44 | errCh <- uut.wait(ctx) |
| 45 | }() |
| 46 | uut.complete(err) |
| 47 | got := testutil.TryReceive(ctx, t, errCh) |
| 48 | require.Equal(t, err, got) |
| 49 | } |
nothing calls this directly
no test coverage detected