mirror of
https://github.com/internetee/registry.git
synced 2025-06-05 04:07:33 +02:00
Fix registration deadline format for whois/restwhois
This commit is contained in:
parent
6f76dd927b
commit
7cfc5efd36
2 changed files with 5 additions and 3 deletions
|
@ -24,7 +24,7 @@ class Auction < ApplicationRecord
|
|||
end
|
||||
|
||||
def whois_deadline
|
||||
registration_deadline.to_s
|
||||
registration_deadline.try(:to_s, :iso8601)
|
||||
end
|
||||
|
||||
def mark_as_no_bids
|
||||
|
|
|
@ -50,7 +50,8 @@ class Whois::RecordTest < ActiveSupport::TestCase
|
|||
assert_equal ({ 'name' => 'domain.test',
|
||||
'status' => ['PendingRegistration'],
|
||||
'disclaimer' => 'disclaimer',
|
||||
'registration_deadline' => registration_deadline.to_s }), @whois_record.json
|
||||
'registration_deadline' => registration_deadline.try(:to_s, :iso8601) }),
|
||||
@whois_record.json
|
||||
end
|
||||
|
||||
def test_updates_whois_record_from_auction_when_payment_received
|
||||
|
@ -64,7 +65,8 @@ class Whois::RecordTest < ActiveSupport::TestCase
|
|||
assert_equal ({ 'name' => 'domain.test',
|
||||
'status' => ['PendingRegistration'],
|
||||
'disclaimer' => 'disclaimer',
|
||||
'registration_deadline' => registration_deadline.to_s }), @whois_record.json
|
||||
'registration_deadline' => registration_deadline.try(:to_s, :iso8601) }),
|
||||
@whois_record.json
|
||||
end
|
||||
|
||||
def registration_deadline
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue