mirror of
https://github.com/fbarresi/Sharp7.git
synced 2026-02-04 08:42:51 +00:00
25 lines
521 B
C#
25 lines
521 B
C#
using System;
|
|
using System.Linq;
|
|
using Shouldly;
|
|
|
|
namespace Sharp7.Tests
|
|
{
|
|
public class ServerTestBase : IDisposable
|
|
{
|
|
private readonly S7Server server;
|
|
protected readonly string Localhost = "127.0.0.1";
|
|
public ServerTestBase()
|
|
{
|
|
server = new S7Server();
|
|
var rc = server.StartTo(Localhost);
|
|
rc.ShouldBe(0);
|
|
}
|
|
|
|
public S7Server Server => server;
|
|
|
|
public void Dispose()
|
|
{
|
|
server.Stop();
|
|
}
|
|
}
|
|
} |