Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add missing integration-level job snooze test (#31)
I noticed while trying to refactor something the other day that I had a problem around snoozing, but only the example snooze test was failing. Looking into it further, it turned out that it was because the snooze example was the only snooze test we had. Example tests aren't great because they do obnoxious things like swallow all output (making it harder to debug), but they also don't support some feature like `-count`, making it harder to debug intermittent problems. Here, add another client test for snooze. We use the new client test line that makes use of `JobArgsReflectKind` and `WorkFunc`, keeping the implementation clean and all local to the specific test case that needs it. And since snooze and cancel are quite similar, I added a test case for cancel as well. Cancel did have another test elsewhere, but I figure I might as well add one in this new line too to line up with the snooze test case. It should be a pretty fast test, so doesn't hurt to have a duplicate.
- Loading branch information