crypto_arbitrer 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/crypto_arbitrer/spec_helper.rb +1 -0
- data/lib/crypto_arbitrer/version.rb +1 -1
- data/spec/base_spec.rb +1 -1
- metadata +1 -1
@@ -5,6 +5,7 @@ module CryptoArbitrer
|
|
5
5
|
.to_return(body: open(File.expand_path("../../../spec/mocks/#{mock_name}", __FILE__)).read)
|
6
6
|
end
|
7
7
|
def mock_crypto_arbitrer_requests!
|
8
|
+
stub_crypto_arbitrer_get("https://btc-e.com/exchange/btc_usd", "btce_btc_usd.html")
|
8
9
|
stub_crypto_arbitrer_get("http://www.eldolarblue.net/getDolarBlue.php?as=json", 'dolarblue.json')
|
9
10
|
stub_crypto_arbitrer_get('http://data.mtgox.com/api/2/BTCUSD/money/ticker_fast', 'mtgox.json')
|
10
11
|
stub_crypto_arbitrer_get('http://www.dolarparalelo.org/', 'dolarparalelo.html')
|
data/spec/base_spec.rb
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
require_relative '../lib/crypto_arbitrer.rb'
|
2
2
|
require 'webmock/rspec'
|
3
3
|
require 'csv'
|
4
|
-
require 'ruby-debug'
|
5
4
|
RSpec.configure do |config|
|
6
5
|
config.include CryptoArbitrer::SpecHelper
|
7
6
|
end
|
@@ -60,6 +59,7 @@ describe CryptoArbitrer::Base do
|
|
60
59
|
rate['buy'].should == 99.999
|
61
60
|
rate['sell'].should == 99.502
|
62
61
|
stub.should have_been_requested
|
62
|
+
CryptoArbitrer::Base.btc_usd_strategy = :mtgox
|
63
63
|
end
|
64
64
|
|
65
65
|
it 'hits dolarparalelo for venezuelan bolivar' do
|