Make the test a bit more robust

As it (sadly) actually relies on the lookup of the data we do not
control what the result will be.
But in this case make sure we select the expected currency.
This commit is contained in:
bumi 2018-11-01 12:21:55 +01:00
parent 7c12457769
commit 6e3b03abda
1 changed files with 1 additions and 1 deletions

View File

@ -7,7 +7,7 @@ RSpec.describe Openalias do
it "provides accessors for the data" do
expect(Openalias.addresses('donate.getmonero.org')[0].recipient_name).to eql('Monero Development')
expect(Openalias.addresses('donate.getmonero.org')[0].address).to eql('44AFFq5kSiGBoZ4NMDwYtN18obc8AemS33DBLWs3H7otXft3XjrpDtQGv7SqSsaBYBb98uNbr2VBBEt7f2wfn3RVGQBEP3A')
expect(Openalias.addresses('donate.getmonero.org').find { |c| c.cryptocurrency.downcase == 'xmr' }.address).to eql('44AFFq5kSiGBoZ4NMDwYtN18obc8AemS33DBLWs3H7otXft3XjrpDtQGv7SqSsaBYBb98uNbr2VBBEt7f2wfn3RVGQBEP3A')
end
it "returns and crypto addresses array" do