From 9321a597638ebf5aae853efa7f3c724a14b89b2e Mon Sep 17 00:00:00 2001 From: bwatson78 Date: Wed, 24 Jan 2024 15:49:28 -0600 Subject: [PATCH] Fixes flaky test in spec/jobs/embargo_expiry_job_spec.rb. --- spec/jobs/embargo_expiry_job_spec.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spec/jobs/embargo_expiry_job_spec.rb b/spec/jobs/embargo_expiry_job_spec.rb index f291402bb8..0f95b6b197 100644 --- a/spec/jobs/embargo_expiry_job_spec.rb +++ b/spec/jobs/embargo_expiry_job_spec.rb @@ -9,8 +9,8 @@ describe '#records_with_expired_embargos' do it 'returns all records with expired embargos' do - records = [work_with_expired_embargo.id, file_set_with_expired_embargo.id] - expect(described_class.new.records_with_expired_embargos.map(&:id)).to eq(records) + records = [work_with_expired_embargo.id.to_s, file_set_with_expired_embargo.id.to_s] + expect(described_class.new.records_with_expired_embargos.map { |r| r.id.to_s }).to match_array(records) end end