diff --git a/CHANGELOG.md b/CHANGELOG.md index 330fec1..f018c04 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # eu_central_bank changelog +## Upcoming release (unreleased) + +* **Breaking change**: Require Ruby >= 3.1 * Update YAML loading from compatibility with recent Psych versions. * Move Croatian Kuna (HRK) and Russian Ruble (RUB) to legacy currencies @@ -9,7 +12,7 @@ ## 1.6.1 (Mar 3 2021) -* Allow a fallback when loading cached rate files to inhibit network fetch. +* Allow a fallback when loading cached rate files to inhibit network fetch. ## 1.5.0 (Dec 7 2019) diff --git a/README.md b/README.md index 9a3178e..3e8b08a 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,7 @@ # eu_central_bank -[![Build Status](https://travis-ci.org/RubyMoney/eu_central_bank.svg?branch=master)](https://travis-ci.org/RubyMoney/eu_central_bank) +[![Gem Version](https://badge.fury.io/rb/eu_central_bank.svg)](https://rubygems.org/gems/eu_central_bank) +[![Ruby](https://github.com/RubyMoney/eu_central_bank/actions/workflows/ruby.yml/badge.svg)](https://github.com/RubyMoney/eu_central_bank/actions/workflows/ruby.yml) ## Introduction @@ -12,15 +13,10 @@ This gem downloads the exchange rates from the European Central Bank. You can ca gem install eu_central_bank ``` -In case you're using older ruby (< 2.1) you need nokogiri < 1.6.8, so add this to your `Gemfile`: - -``` -gem 'nokogiri', '1.6.8' -``` - ## Dependencies - nokogiri +- bigdecimal - money ## Usage @@ -72,9 +68,9 @@ eu_bank.exchange_with(Money.new(100, "CAD"), "USD") # Money.new(80, "USD") - Fork the project. - Make your feature addition or bug fix. -- Add tests for it. This is important so I don't break it in a future version unintentionally. +- Add tests for it. This is important so I don't break it in a future version unintentionally. - Commit, do not mess with rakefile, version, or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull) ## Copyright -Copyright (c) 2010-2016 RubyMoney. See LICENSE for details. +Copyright (c) 2010-2025 RubyMoney. See LICENSE for details. diff --git a/eu_central_bank.gemspec b/eu_central_bank.gemspec index 41c283d..af1af90 100755 --- a/eu_central_bank.gemspec +++ b/eu_central_bank.gemspec @@ -21,7 +21,7 @@ Gem::Specification.new do |s| s.add_dependency "nokogiri", "~> 1.11" s.add_dependency "money", "~> 6.19" - s.add_development_dependency "rspec", "~> 3.12.0" + s.add_development_dependency "rspec", "~> 3.13" s.files = Dir.glob("lib/**/*") + %w(CHANGELOG.md LICENSE README.md) s.require_path = "lib" diff --git a/spec/eu_central_bank_spec.rb b/spec/eu_central_bank_spec.rb index f1ad674..0010c8c 100644 --- a/spec/eu_central_bank_spec.rb +++ b/spec/eu_central_bank_spec.rb @@ -2,6 +2,8 @@ describe "EuCentralBank" do before(:each) do + Money.rounding_mode = BigDecimal::ROUND_HALF_UP + @bank = EuCentralBank.new @dir_path = File.dirname(__FILE__) @cache_path = File.expand_path(@dir_path + '/exchange_rates.xml')