diff options
| author | Stefan van den Oord <stefan@viduet.eu> | 2025-09-16 10:36:07 +0200 |
|---|---|---|
| committer | Stefan van den Oord <stefan@viduet.eu> | 2025-09-16 10:36:07 +0200 |
| commit | 8b46092126baea5cd73465f5d544cdb0f75547b6 (patch) | |
| tree | 534c815acad73984ab0bd36b89049b23cd269ae0 /test/com/github/ivarref/yoltq | |
| parent | Merge branch 'main' into batches-of-jobs (diff) | |
| download | fiinha-8b46092126baea5cd73465f5d544cdb0f75547b6.tar.gz fiinha-8b46092126baea5cd73465f5d544cdb0f75547b6.tar.xz | |
Rename batch -> job-group
Diffstat (limited to 'test/com/github/ivarref/yoltq')
| -rw-r--r-- | test/com/github/ivarref/yoltq/virtual_test.clj | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/test/com/github/ivarref/yoltq/virtual_test.clj b/test/com/github/ivarref/yoltq/virtual_test.clj index 7621b13..d245aaa 100644 --- a/test/com/github/ivarref/yoltq/virtual_test.clj +++ b/test/com/github/ivarref/yoltq/virtual_test.clj @@ -451,24 +451,24 @@ (tq/consume! :q) (is (= @got-work "asdf")))) -(deftest batch-of-jobs-test +(deftest job-group-test (let [conn (u/empty-conn)] (yq/init! {:conn conn}) (yq/add-consumer! :q1 identity) (yq/add-consumer! :q2 identity) - @(d/transact conn [(yq/put :q1 {:work 123} {:batch-name :b1}) - (yq/put :q1 {:work 456} {:batch-name :b2}) - (yq/put :q2 {:work 789} {:batch-name :b1})]) + @(d/transact conn [(yq/put :q1 {:work 123} {:job-group-name :b1}) + (yq/put :q1 {:work 456} {:job-group-name :b2}) + (yq/put :q2 {:work 789} {:job-group-name :b1})]) (is (= [{:qname :q1 - :batch-name :b1 + :job-group-name :b1 :status :init :count 1}] - (yq/batch-progress :q1 :b1))) + (yq/job-group-progress :q1 :b1))) (is (= {:work 123} (tq/consume! :q1))) (is (= [{:qname :q1 - :batch-name :b1 + :job-group-name :b1 :status :done :count 1}] - (yq/batch-progress :q1 :b1))))) + (yq/job-group-progress :q1 :b1))))) |
