Skip to content

Commit ec40363

Browse files
Separate unit and integration tests
1 parent a6c607f commit ec40363

18 files changed

Lines changed: 64 additions & 21 deletions

.github/workflows/dotnet.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,12 @@ jobs:
2929
- name: Build
3030
run: dotnet build --no-restore
3131

32+
- name: Run unit tests
33+
run: dotnet test Monero.UnitTests/Monero.UnitTests.csproj --no-build --logger:trx
34+
3235
- name: Run integration tests
33-
run: docker compose -f Monero.Test/docker-compose.yml run tests
36+
run: docker compose -f Monero.IntegrationTests/docker-compose.yml run tests
3437

3538
- name: Cleanup Docker containers
3639
if: always()
37-
run: docker compose -f Monero.Test/docker-compose.yml down -v
40+
run: docker compose -f Monero.IntegrationTests/docker-compose.yml down -v
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ RUN dotnet restore
88

99
RUN dotnet build --no-restore
1010

11-
CMD ["dotnet", "test", "--filter", "TestMoneroUtils|TestMoneroRpcConnection|TestMoneroDaemonRpc", "--no-build", "--logger:trx"]
11+
CMD ["dotnet", "test", "--filter", "TestMoneroRpcConnection|TestMoneroDaemonRpc", "--no-build", "--logger:trx"]

Monero.Test/Monero.Test.csproj renamed to Monero.IntegrationTests/Monero.IntegrationTests.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,8 @@
2424
<Using Include="Xunit"/>
2525
</ItemGroup>
2626

27+
<ItemGroup>
28+
<Folder Include="TestResults\" />
29+
</ItemGroup>
30+
2731
</Project>

Monero.Test/TestMoneroConnectionManager.cs renamed to Monero.IntegrationTests/TestMoneroConnectionManager.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
using Monero.Common;
2-
using Monero.Test.Utils;
2+
using Monero.IntegrationTests.Utils;
33
using Monero.Wallet;
44

5-
namespace Monero.Test;
5+
namespace Monero.IntegrationTests;
66

77
public class TestMoneroConnectionManager
88
{

Monero.Test/TestMoneroDaemonRpc.cs renamed to Monero.IntegrationTests/TestMoneroDaemonRpc.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
using Monero.Common;
44
using Monero.Daemon;
55
using Monero.Daemon.Common;
6-
using Monero.Test.Utils;
6+
using Monero.IntegrationTests.Utils;
77
using Monero.Wallet;
88
using Monero.Wallet.Common;
99

10-
namespace Monero.Test;
10+
namespace Monero.IntegrationTests;
1111

1212
public class MoneroDaemonRpcFixture : IDisposable
1313
{

Monero.Test/TestMoneroRpcConnection.cs renamed to Monero.IntegrationTests/TestMoneroRpcConnection.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using Monero.Common;
2-
using Monero.Test.Utils;
2+
using Monero.IntegrationTests.Utils;
33

4-
namespace Monero.Test;
4+
namespace Monero.IntegrationTests;
55

66
public class TestMoneroRpcConnection
77
{

Monero.Test/TestMoneroWalletCommon.cs renamed to Monero.IntegrationTests/TestMoneroWalletCommon.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
using Monero.Common;
22
using Monero.Daemon;
3-
using Monero.Test.Utils;
3+
using Monero.IntegrationTests.Utils;
44
using Monero.Wallet;
55
using Monero.Wallet.Common;
66

7-
namespace Monero.Test;
7+
namespace Monero.IntegrationTests;
88

99
public abstract class TestMoneroWalletCommon
1010
{

Monero.Test/TestMoneroWalletLight.cs renamed to Monero.IntegrationTests/TestMoneroWalletLight.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using Monero.Wallet;
22
using Monero.Wallet.Common;
33

4-
namespace Monero.Test;
4+
namespace Monero.IntegrationTests;
55

66
public class TestMoneroWalletLight : TestMoneroWalletCommon
77
{

Monero.Test/TestMoneroWalletRpc.cs renamed to Monero.IntegrationTests/TestMoneroWalletRpc.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
using Monero.Common;
2-
using Monero.Test.Utils;
2+
using Monero.IntegrationTests.Utils;
33
using Monero.Wallet;
44
using Monero.Wallet.Common;
55

6-
namespace Monero.Test;
6+
namespace Monero.IntegrationTests;
77

88
public class TestMoneroWalletRpc : TestMoneroWalletCommon
99
{

Monero.Test/Utils/StartMining.cs renamed to Monero.IntegrationTests/Utils/StartMining.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
namespace Monero.Test.Utils;
1+
namespace Monero.IntegrationTests.Utils;
22

33
public static class StartMining
44
{

0 commit comments

Comments
 (0)