- add a small integration test:

Test connects to a local server and just calls a method
pull/26/head
Simon Gockner 6 years ago
parent 61e0e52ecc
commit b7152a502c
  1. 11
      Test.GBase.Client/IntegrationTest.cs
  2. 6
      Test.GBase.Client/Test.GBase.Client.csproj

@ -1,3 +1,7 @@
using System.Net;
using GBase.Api.Communication;
using GBase.Client;
using GBase.Client.Interfaces;
using NUnit.Framework;
namespace Test.GBase.Client
@ -13,7 +17,12 @@ namespace Test.GBase.Client
[Test]
public void CheckBasicConnectionWithServer()
{
Assert.Pass();
IGBaseClientSettings settings =
new GBaseClientSettings(ServerProtocol.Http, IPAddress.Parse("127.0.0.1"), 8080, "/GBase", "/GBaseTable", "/GBaseEntry");
IGBaseClient client = new GBaseClient(settings);
bool ret = client.GBase.AddTable();
Assert.True(ret);
}
}
}

@ -9,7 +9,11 @@
<ItemGroup>
<PackageReference Include="nunit" Version="3.12.0" />
<PackageReference Include="NUnit3TestAdapter" Version="3.15.1" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.4.0"/>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.4.0" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\GBase.Client\GBase.Client.csproj" />
</ItemGroup>
</Project>

Loading…
Cancel
Save