Skip to content
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

Merge develop into master #279

Merged
merged 48 commits into from
Nov 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
2889f02
Update SDK and Extensions dependencies and fix some minor R# issues i…
OlegRa Nov 10, 2022
17be5b8
Upgrade dependencies (DateTimeOnly package)
OlegRa Nov 21, 2022
a6762fd
Bump Microsoft.NET.Test.Sdk from 17.4.0 to 17.4.1 (#238)
dependabot[bot] Dec 23, 2022
db99d34
Bump Portable.System.DateTimeOnly from 6.0.3 to 7.0.0 (#239)
dependabot[bot] Jan 3, 2023
b37df5c
Bump Microsoft.NET.Test.Sdk from 17.4.1 to 17.5.0 (#240)
dependabot[bot] Feb 23, 2023
fd3bc60
Bump Alpaca.Markets from 7.0.0-alpha1 to 7.0.0-alpha2 (#241)
dependabot[bot] Mar 13, 2023
df946d8
Bump Portable.System.DateTimeOnly from 7.0.0 to 7.0.1 (#242)
dependabot[bot] Mar 13, 2023
d43af65
Upgrade dependencies and add a new TFM - .NET 7.0 & .NET Framework 4.…
OlegRa Mar 13, 2023
7c49f67
Bump Alpaca.Markets from 7.0.0-alpha2 to 7.0.0-alpha3 (#243)
dependabot[bot] Apr 16, 2023
d3698bb
Bump Microsoft.NET.Test.Sdk from 17.5.0 to 17.6.0 (#244)
dependabot[bot] May 17, 2023
c49c1fd
Bump Microsoft.NET.Test.Sdk from 17.6.0 to 17.6.1 (#245)
dependabot[bot] Jun 4, 2023
7b59dfd
Bump Microsoft.NET.Test.Sdk from 17.6.1 to 17.6.2 (#248)
dependabot[bot] Jun 8, 2023
8a58273
Bump Alpaca.Markets from 7.0.0-alpha3 to 7.0.0-alpha4 (#246)
dependabot[bot] Jun 8, 2023
9dea69c
Bump Alpaca.Markets.Extensions from 7.0.0-alpha1 to 7.0.0-alpha2 (#247)
dependabot[bot] Jun 8, 2023
ea80f0b
Bump Microsoft.NET.Test.Sdk from 17.6.2 to 17.6.3 (#249)
dependabot[bot] Jun 30, 2023
286b4a9
All GitHub actions updated - the .NET SDK 7.0.x used for all activiti…
OlegRa Jun 8, 2023
6d21c7e
Fixed CodeQL issue related to xUnit assertion (non-critical).
OlegRa Jul 7, 2023
1e8f96c
Some integration tests were changed to prevent failures in case of an…
OlegRa Jul 7, 2023
8ab0dec
Bump xunit from 2.4.2 to 2.5.0 (#250)
dependabot[bot] Jul 7, 2023
8a6a055
Bump xunit.runner.visualstudio from 2.4.5 to 2.5.0 (#251)
dependabot[bot] Jul 7, 2023
74fd7ed
Bump Microsoft.NET.Test.Sdk from 17.6.3 to 17.7.0 (#252)
dependabot[bot] Aug 9, 2023
cafdb75
Bump Microsoft.NET.Test.Sdk from 17.7.0 to 17.7.1 (#253)
dependabot[bot] Aug 19, 2023
dbdd22c
Bump IndexRange from 1.0.2 to 1.0.3 (#254)
dependabot[bot] Aug 23, 2023
2e07096
Upgrade both SDK and Extensions packages up to 7.0.0-beta1
OlegRa Aug 27, 2023
ca047b8
Bump Microsoft.NET.Test.Sdk from 17.7.1 to 17.7.2 (#255)
dependabot[bot] Aug 30, 2023
7b7d28d
Bump Alpaca.Markets from 7.0.0-beta1 to 7.0.0-beta2 (#256)
dependabot[bot] Sep 8, 2023
333f77e
Bump xunit.runner.visualstudio from 2.5.0 to 2.5.1 (#260)
dependabot[bot] Sep 18, 2023
6441528
Bump xunit from 2.5.0 to 2.5.1 (#257)
dependabot[bot] Sep 18, 2023
a5df526
Bump Alpaca.Markets from 7.0.0-beta2 to 7.0.0-rc1 (#259)
dependabot[bot] Sep 18, 2023
f82f111
Bump Alpaca.Markets.Extensions from 7.0.0-beta1 to 7.0.0-rc1 (#258)
dependabot[bot] Sep 18, 2023
94e24e1
Issue #262 - fixed compilation and runtime issues after last xUnit up…
OlegRa Oct 9, 2023
5826156
Bump Alpaca.Markets from 7.0.0-rc1 to 7.0.0-rc2 (#261)
dependabot[bot] Oct 9, 2023
ff626b2
Bump xunit.runner.visualstudio from 2.5.1 to 2.5.3 (#263)
dependabot[bot] Oct 15, 2023
9785174
Bump xunit from 2.5.1 to 2.5.2 (#264)
dependabot[bot] Oct 15, 2023
ac7999b
Bump xunit from 2.5.2 to 2.5.3 (#265)
dependabot[bot] Oct 23, 2023
7ac2dec
Bump xunit from 2.5.3 to 2.6.1 (#267)
dependabot[bot] Nov 4, 2023
34cc5c3
Bump Microsoft.NET.Test.Sdk from 17.7.2 to 17.8.0 (#268)
dependabot[bot] Nov 11, 2023
db56204
Bump Alpaca.Markets from 7.0.0-rc2 to 7.0.0-rc3 (#269)
dependabot[bot] Nov 15, 2023
3280978
Bump Microsoft.Extensions.Configuration.Abstractions from 7.0.0 to 8.…
dependabot[bot] Nov 15, 2023
d4cebde
Bump Microsoft.Extensions.Configuration from 7.0.0 to 8.0.0 (#270)
dependabot[bot] Nov 15, 2023
26e8dff
Bump Microsoft.Extensions.Configuration.EnvironmentVariables (#272)
dependabot[bot] Nov 15, 2023
0fe8c68
Bump Microsoft.Extensions.Configuration.Json from 7.0.0 to 8.0.0 (#273)
dependabot[bot] Nov 15, 2023
abc2bb3
Bump Portable.System.DateTimeOnly from 7.0.1 to 8.0.0 (#275)
dependabot[bot] Nov 17, 2023
4e0b511
Bump Alpaca.Markets from 7.0.0-rc3 to 7.0.0 (#274)
dependabot[bot] Nov 17, 2023
da51002
Bump xunit from 2.6.1 to 2.6.2 (#277)
dependabot[bot] Nov 20, 2023
7ea2ba4
Bump xunit.runner.visualstudio from 2.5.3 to 2.5.4 (#278)
dependabot[bot] Nov 20, 2023
2c49e54
Bump Alpaca.Markets.Extensions from 7.0.0-rc1 to 7.0.0 (#276)
dependabot[bot] Nov 20, 2023
0b38080
Merge branch 'master' into develop
OlegRa Nov 20, 2023
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
20 changes: 10 additions & 10 deletions Alpaca.Markets.Tests.All/Alpaca.Markets.Tests.All.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
Expand All @@ -12,15 +12,15 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Alpaca.Markets" Version="6.2.5" />
<PackageReference Include="Alpaca.Markets.Extensions" Version="6.2.2" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="7.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.2" />
<PackageReference Include="xunit" Version="2.5.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.3">
<PackageReference Include="Alpaca.Markets" Version="7.0.0" />
<PackageReference Include="Alpaca.Markets.Extensions" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="8.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="xunit" Version="2.6.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.4">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
Expand Down
22 changes: 11 additions & 11 deletions Alpaca.Markets.Tests.Win/Alpaca.Markets.Tests.Win.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net472;net48;net481</TargetFrameworks>
Expand All @@ -12,17 +12,17 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Alpaca.Markets" Version="6.2.5" />
<PackageReference Include="Alpaca.Markets.Extensions" Version="6.2.2" />
<PackageReference Include="Alpaca.Markets" Version="7.0.0" />
<PackageReference Include="Alpaca.Markets.Extensions" Version="7.0.0" />
<PackageReference Include="IndexRange" Version="1.0.3" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="7.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.2" />
<PackageReference Include="Portable.System.DateTimeOnly" Version="7.0.1" />
<PackageReference Include="xunit" Version="2.5.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.3">
<PackageReference Include="Microsoft.Extensions.Configuration" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="8.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="Portable.System.DateTimeOnly" Version="8.0.0" />
<PackageReference Include="xunit" Version="2.6.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.4">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
Expand Down
30 changes: 2 additions & 28 deletions Alpaca.Markets.Tests/AlpacaCryptoDataClientTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -57,39 +57,13 @@ public async void GetDayHistoricalBarsWorks()
AssertPageIsValid(bars, AssertBarIsValid);
}

[Fact]
public async void ListHistoricalQuotesWorks()
{
var into = (await GetLastTradingDayCloseTimeUtc()).Date;
var from = into.AddDays(-3).Date;
#pragma warning disable CS0618
var quotes = await Client.ListHistoricalQuotesAsync(
new HistoricalCryptoQuotesRequest(Symbol, from, into));
#pragma warning restore CS0618

AssertPageIsValid(quotes, AssertQuoteIsValid, false);
}

[Fact]
public async void GetHistoricalQuotesWorks()
{
var into = (await GetLastTradingDayCloseTimeUtc()).Date;
var from = into.AddDays(-3).Date;
#pragma warning disable CS0618
var quotes = await Client.GetHistoricalQuotesAsync(
new HistoricalCryptoQuotesRequest(Symbols, from, into));
#pragma warning restore CS0618

AssertPageIsValid(quotes, AssertQuoteIsValid, false);
}

[Fact]
public async void ListHistoricalTradesWorks()
{
var into = (await GetLastTradingDayCloseTimeUtc()).Date;
var from = into.AddDays(-1).Date;
var trades = await Client.ListHistoricalTradesAsync(
new HistoricalCryptoTradesRequest(Symbol, from, into));
new HistoricalCryptoTradesRequest(Symbol, from, into).WithPageSize(10));

AssertPageIsValid(trades, AssertTradeIsValid);
}
Expand All @@ -100,7 +74,7 @@ public async void GetHistoricalTradesWorks()
var into = (await GetLastTradingDayCloseTimeUtc()).Date;
var from = into.AddDays(-1).Date;
var trades = await Client.GetHistoricalTradesAsync(
new HistoricalCryptoTradesRequest(Symbols, from, into));
new HistoricalCryptoTradesRequest(Symbols, from, into).WithPageSize(10));

AssertPageIsValid(trades, AssertTradeIsValid);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,20 +59,20 @@ public async Task AsyncEnumerableWorks()
var cancellationTokenSource = new CancellationTokenSource();
cancellationTokenSource.CancelAfter(TimeSpan.FromSeconds(15));

var subscription = await client.SubscribeTradeAsync(Symbol);
var subscription = await client.SubscribeQuoteAsync(Symbol);
await using (subscription.ConfigureAwait(false))
{
var atLeastOneTradeReceived = false;
var atLeastOneQuoteReceived = false;

await foreach (var _ in subscription
.AsAsyncEnumerable(cancellationTokenSource.Token)
.ConfigureAwait(false))
{
atLeastOneTradeReceived = true;
atLeastOneQuoteReceived = true;
break;
}

Assert.True(atLeastOneTradeReceived);
Assert.True(atLeastOneQuoteReceived);
}

await client.DisconnectAsync(CancellationToken.None);
Expand Down
4 changes: 2 additions & 2 deletions Alpaca.Markets.Tests/AlpacaDataClientTest.Extensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public async void GetHistoricalBarsAsAsyncEnumerableWorks()
var into = (await GetLastTradingDayCloseTimeUtc()).Date;
var from = into.AddDays(-5).Date;
await foreach (var bar in Client.GetHistoricalBarsAsAsyncEnumerable(
new HistoricalBarsRequest(Symbol, from, into, BarTimeFrame.Hour)))
new HistoricalBarsRequest(Symbol, from, into, BarTimeFrame.Hour)))
{
Assert.NotNull(bar);
Assert.InRange(bar.TimeUtc, from, into);
Expand All @@ -31,7 +31,7 @@ public async void GetHistoricalQuotesAsAsyncEnumerableWorks()
try
{
await foreach (var quote in Client.GetHistoricalQuotesAsAsyncEnumerable(
new HistoricalQuotesRequest(Symbol, from, into), cancellationTokenSource.Token))
new HistoricalQuotesRequest(Symbol, from, into), cancellationTokenSource.Token))
{
Assert.NotNull(quote);
Assert.InRange(quote.TimestampUtc, from, into);
Expand Down
Loading