added tests for sharp7 client

This commit is contained in:
Federico Barresi
2019-10-30 13:27:00 +01:00
parent 181b170eb7
commit 2be6622c2b
7 changed files with 569 additions and 3 deletions

View File

@@ -0,0 +1,26 @@
using System;
using System.Linq;
using Shouldly;
namespace Sharp7.Tests
{
public class ServerClientTestBase : ServerTestBase, IDisposable
{
private S7Client client;
public S7Client Client => client;
public ServerClientTestBase() : base()
{
client = new S7Client();
var rc = client.ConnectTo(Localhost, 0, 2);
rc.ShouldBe(0);
}
public new void Dispose()
{
client.Disconnect();
base.Dispose();
}
}
}