public void EventDataPlayerSessionCollection_RemoveSession_SimpleCase() { EventDataPlayerSessionCollection edpsc = new EventDataPlayerSessionCollection((DiagnosticEvent x) => true); edpsc.AddSession("Test session", 0); edpsc.RemoveSession(0); Assert.AreEqual(0, edpsc.GetSessionCount(), "Session was not properly removed."); }
public void EventDataPlayerSessionCollection_TestPlayerConnection() { EventDataPlayerSessionCollection edpsc = new EventDataPlayerSessionCollection((DiagnosticEvent x) => true); edpsc.AddSession("Default", 0); edpsc.GetPlayerSession(1000, true).IsActive = true; Assert.AreEqual(2, edpsc.GetSessionCount(), "Session not properly added. "); int connectedSessionIndex = edpsc.GetSessionIndexById(1000); Assert.AreEqual(1, connectedSessionIndex, "Session index not properly set. "); }