@@ -23,13 +23,13 @@ def perform(arg)
23
23
end
24
24
25
25
test "batch will be completed on success" do
26
- batch = SolidQueue ::JobBatch . enqueue ( on_finish : BatchCompletionJob ) { }
26
+ batch = SolidQueue ::JobBatch . enqueue ( on_finish : BatchCompletionJob ) { }
27
27
assert_not_nil batch . on_finish_active_job
28
28
assert_equal BatchCompletionJob . name , batch . on_finish_active_job [ "job_class" ]
29
29
end
30
30
31
31
test "batch will be completed on finish" do
32
- batch = SolidQueue ::JobBatch . enqueue ( on_success : BatchCompletionJob ) { }
32
+ batch = SolidQueue ::JobBatch . enqueue ( on_success : BatchCompletionJob ) { }
33
33
assert_not_nil batch . on_success_active_job
34
34
assert_equal BatchCompletionJob . name , batch . on_success_active_job [ "job_class" ]
35
35
end
@@ -41,7 +41,7 @@ def perform(arg)
41
41
end
42
42
43
43
assert_equal 2 , SolidQueue ::Job . count
44
- assert_equal [ batch . id ] * 2 , SolidQueue ::Job . last ( 2 ) . map ( &:batch_id )
44
+ assert_equal [ batch . id ] * 2 , SolidQueue ::Job . last ( 2 ) . map ( &:batch_id )
45
45
end
46
46
47
47
test "batch id is present inside the block" do
@@ -60,7 +60,7 @@ def perform(arg)
60
60
end
61
61
62
62
assert_not_nil SolidQueue ::JobBatch . last . on_finish_active_job [ "arguments" ]
63
- assert_equal SolidQueue ::JobBatch . last . on_finish_active_job [ "arguments" ] , [ 1 , 2 ]
63
+ assert_equal SolidQueue ::JobBatch . last . on_finish_active_job [ "arguments" ] , [ 1 , 2 ]
64
64
assert_equal SolidQueue ::JobBatch . last . on_finish_active_job [ "queue_name" ] , "batch"
65
65
end
66
66
end
0 commit comments