Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -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

Expand All @@ -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)

Expand Down
14 changes: 5 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -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

Expand All @@ -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
Expand Down Expand Up @@ -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.
2 changes: 1 addition & 1 deletion eu_central_bank.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
2 changes: 2 additions & 0 deletions spec/eu_central_bank_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -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')
Expand Down