Skip to content

Commit b54d0f1

Browse files
committed
removed unit test
1 parent 1152a69 commit b54d0f1

File tree

1 file changed

+0
-18
lines changed

1 file changed

+0
-18
lines changed

test/test_jobs.rb

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -53,22 +53,4 @@ def test_set_processing_duration
5353
assert_equal(expect_duration, actual_duration)
5454
end
5555
end
56-
57-
def test_get_failed_bag_ids
58-
failed_status = [BagStatus::DEPOSIT_SKIPPED, BagStatus::FAILED, BagStatus::VALIDATION_SKIPPED, BagStatus::VERIFY_FAILED]
59-
60-
bag_mock = Minitest::Mock.new
61-
bag_mock.expect(:join, bag_mock,[:status_event, Sequel.qualify(:status_event, :bag_id) => Sequel.qualify(:bag, :id)])
62-
bag_mock.expect(:join, bag_mock, [:status, Sequel.qualify(:status, :id) => Sequel.qualify(:status_event, :status_id)])
63-
bag_mock.expect(:where, bag_mock, [Sequel.qualify(:status_event, :timestamp) >= @start_time])
64-
bag_mock.expect(:where, bag_mock, [Sequel.qualify(:status, :name).like("%#{failed_status.join('%')}%")])
65-
bag_mock.expect(:group, bag_mock, [Sequel[:bag][:identifier]])
66-
bag_mock.expect(:select_map, ['4355a','hgfb5'], Sequel[:bag][:identifier])
67-
68-
DatabaseSchema::Bag.stub(:call, bag_mock) do
69-
failed_bag_ids = @metrics.get_failed_bag_ids
70-
expected_bag_ids = ['4355a','hgfb5']
71-
assert_equal expected_bag_ids, failed_bag_ids
72-
end
73-
end
7456
end

0 commit comments

Comments
 (0)