(ctx context.Context, t testingT, driver TDriver, expectedJob TArgs, opts *RequireInsertedOpts)
| 108 | } |
| 109 | |
| 110 | func requireInserted[TDriver riverdriver.Driver[TTx], TTx any, TArgs river.JobArgs](ctx context.Context, t testingT, driver TDriver, expectedJob TArgs, opts *RequireInsertedOpts) *river.Job[TArgs] { |
| 111 | t.Helper() |
| 112 | actualArgs, err := requireInsertedErr[TDriver](ctx, t, driver.GetExecutor(), expectedJob, opts) |
| 113 | if err != nil { |
| 114 | failuref(t, "Internal failure: %s", err) |
| 115 | } |
| 116 | return actualArgs |
| 117 | } |
| 118 | |
| 119 | // RequireInsertedTx is a test helper that verifies that a job of the given kind |
| 120 | // was inserted for work, failing the test if it wasn't. If found, the inserted |
searching dependent graphs…