mirror of
https://github.com/internetee/registry.git
synced 2025-06-10 14:44:47 +02:00
Move DomainCron#clean_expired_pendings to interactor
This commit is contained in:
parent
42b9adbf44
commit
e8fa79304f
5 changed files with 112 additions and 33 deletions
|
@ -19,7 +19,9 @@ class DomainCronTest < ActiveSupport::TestCase
|
|||
registrant_verification_token: 'test',
|
||||
statuses: [DomainStatus::PENDING_DELETE_CONFIRMATION])
|
||||
|
||||
DomainCron.clean_expired_pendings
|
||||
perform_enqueued_jobs do
|
||||
DomainCron.clean_expired_pendings
|
||||
end
|
||||
|
||||
assert_emails 1
|
||||
end
|
||||
|
@ -84,7 +86,9 @@ class DomainCronTest < ActiveSupport::TestCase
|
|||
assert @domain.pending_update?
|
||||
@domain.reload
|
||||
|
||||
DomainCron.clean_expired_pendings
|
||||
perform_enqueued_jobs do
|
||||
DomainCron.clean_expired_pendings
|
||||
end
|
||||
@domain.reload
|
||||
|
||||
assert_not @domain.pending_update?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue