Skip to content

[FIX] [Bitfinex] Fixed market symbol separator (#699) #707

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Dec 14, 2021
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
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ private ExchangeBitfinexAPI()
["ZEC"] = "zcash",
};

MarketSymbolSeparator = string.Empty;
MarketSymbolSeparator = ":";
}

public override string PeriodSecondsToString(int seconds)
Expand Down
13 changes: 13 additions & 0 deletions tests/ExchangeSharpTests/ExchangeBitfinexTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ The above copyright notice and this permission notice shall be included in all c
using ExchangeSharp;
using System.Net;
using System.Security;
using System;
using FluentAssertions;

namespace ExchangeSharpTests
{
Expand All @@ -40,5 +42,16 @@ public void SubmitStopMarginOrder()
api.PublicApiKey = _pubKey;
ExchangeOrderResult result = api.PlaceOrderAsync(order).Result;
}

[TestMethod]
public void GetDataFromMarketWithSpecialChar()
{
IExchangeAPI api = ExchangeAPI.GetExchangeAPIAsync("Bitfinex").Result;
string marketTicker = "DOGE:USD";
DateTime start = new DateTime(2021, 12, 1);
DateTime end = DateTime.Today;
System.Collections.Generic.IEnumerable<MarketCandle> result = api.GetCandlesAsync(marketTicker, 86400, start, end, 1000).Result;
result.Should().HaveCountGreaterThan(0, "Returned data");
}
}
}