Fixed tests
This commit is contained in:
parent
e92edbc381
commit
da1bd1fc61
@ -45,8 +45,8 @@ namespace RoboidControl.test {
|
|||||||
|
|
||||||
[Test]
|
[Test]
|
||||||
public void Test_SiteParticipant() {
|
public void Test_SiteParticipant() {
|
||||||
SiteServer siteServer = new SiteServer(7681);
|
SiteServer siteServer = new(7681);
|
||||||
ParticipantUDP participant = new ParticipantUDP("127.0.0.1", 7681);
|
ParticipantUDP participant = new("127.0.0.1", 7681, 7682);
|
||||||
|
|
||||||
ulong milliseconds = (ulong)DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
ulong milliseconds = (ulong)DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
||||||
ulong startTime = milliseconds;
|
ulong startTime = milliseconds;
|
||||||
@ -58,14 +58,14 @@ namespace RoboidControl.test {
|
|||||||
milliseconds = (ulong)DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
milliseconds = (ulong)DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
||||||
}
|
}
|
||||||
|
|
||||||
Assert.That(participant.networkId, Is.EqualTo(1));
|
Assert.That(participant.networkId, Is.EqualTo(2));
|
||||||
}
|
}
|
||||||
|
|
||||||
[Test]
|
[Test]
|
||||||
public void Test_ThingMsg() {
|
public void Test_ThingMsg() {
|
||||||
SiteServer siteServer = new SiteServer(7681);
|
SiteServer siteServer = new(7681);
|
||||||
ParticipantUDP participant = new ParticipantUDP("127.0.0.1");
|
ParticipantUDP participant = new("127.0.0.1", 7681, 7682);
|
||||||
Thing thing = new Thing(participant) {
|
Thing thing = new(participant) {
|
||||||
name = "First Thing",
|
name = "First Thing",
|
||||||
modelUrl = "https://passer.life/extras/ant.jpg"
|
modelUrl = "https://passer.life/extras/ant.jpg"
|
||||||
};
|
};
|
||||||
@ -80,7 +80,7 @@ namespace RoboidControl.test {
|
|||||||
milliseconds = (ulong)DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
milliseconds = (ulong)DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
||||||
}
|
}
|
||||||
|
|
||||||
Assert.That(participant.networkId, Is.EqualTo(1));
|
Assert.That(participant.networkId, Is.EqualTo(2));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user