mirror of
https://github.com/internetee/registry.git
synced 2025-08-05 17:28:18 +02:00
Add specs to accept comma as a fraction separator in billing price
#475
This commit is contained in:
parent
7cadf66920
commit
71102bb5e8
2 changed files with 31 additions and 0 deletions
|
@ -77,6 +77,18 @@ RSpec.describe Billing::Price do
|
|||
price.validate
|
||||
expect(price.errors).to_not have_key(:price)
|
||||
end
|
||||
|
||||
it 'accepts period as fraction separator' do
|
||||
price.price = 1.5
|
||||
price.validate
|
||||
expect(price.errors).to_not have_key(:price)
|
||||
end
|
||||
|
||||
it 'accepts comma as fraction separator' do
|
||||
price.price = '1,5'
|
||||
price.validate
|
||||
expect(price.errors).to_not have_key(:price)
|
||||
end
|
||||
end
|
||||
|
||||
describe 'duration validation', db: false do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue