From 0624f51881e2ca7b8e61f8fba7eeea6ae20f3dd7 Mon Sep 17 00:00:00 2001 From: Lud Date: Mon, 17 Jul 2023 23:58:40 +0200 Subject: [PATCH] expect BigDecimal --- spec/money/distributed/storage_spec.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spec/money/distributed/storage_spec.rb b/spec/money/distributed/storage_spec.rb index 299b808..d3dc39e 100644 --- a/spec/money/distributed/storage_spec.rb +++ b/spec/money/distributed/storage_spec.rb @@ -10,8 +10,8 @@ let(:ttl) { 3600 } it 'stores rates in redis' do - subject.add_rate 'USD', 'RUB', 60.123 - expect(redis.hget(described_class::REDIS_KEY, 'USD_TO_RUB')).to eq '60.123' + subject.add_rate 'USD', 'RUB', BigDecimal('60.123') + expect(redis.hget(described_class::REDIS_KEY, 'USD_TO_RUB')).to eq('0.60123e2') end it 'gets rates from redis' do