spec/integrations/check_spec.rb in onfido-3.4.0 vs spec/integrations/check_spec.rb in onfido-4.0.0
- old
+ new
@@ -9,11 +9,11 @@
it 'creates a check' do
expect(check).not_to be_nil
expect(check).to be_an_instance_of Onfido::Check
expect(check.applicant_id).to eq applicant_id
expect(check.report_ids.size).to eq 2
- expect(check.status).to eq 'in_progress'
+ expect(check.status).to eq Onfido::CheckStatus::IN_PROGRESS
end
context 'consider check' do
let(:check_builder) do
check_builder = Onfido::CheckBuilder.new({
@@ -45,11 +45,11 @@
document_ids: [document_id],
report_names: [Onfido::ReportName::DOCUMENT],
us_driving_licence: us_driving_licence_builder,
})
end
-
+
it 'creates a driving licence check' do
expect(check).not_to be_nil
expect(check).to be_an_instance_of Onfido::Check
expect(check.applicant_id).to eq applicant_id
end
@@ -63,12 +63,12 @@
expect(list_of_checks.checks.size).to be > 0
end
it 'finds a check' do
get_check = onfido_api.find_check(check_id)
-
+
expect(get_check).to be_an_instance_of(Onfido::Check)
- expect(get_check.id).to eq check_id
+ expect(get_check.id).to eq check_id
end
it 'restarts a check' do
onfido_api.resume_check(check_id)
end