public void UnregisteredNameDNT() { Assert.DoesNotThrow(() => UnityDataHolder.changeClientID("", "")); Assert.DoesNotThrow(() => UnityDataHolder.removeClient("")); Assert.DoesNotThrow(() => UnityDataHolder.setString("", ts)); Assert.DoesNotThrow(() => UnityDataHolder.getData("")); }
public Task SendDataToUser() { string message = ClientInfo.getGroup(Context.ConnectionId).Equals("") ? UnityClientList.getClientList() : UnityDataHolder.getData(ClientInfo.getGroup(Context.ConnectionId)); return(Clients.Caller.SendAsync("DataUpdate", message)); }
public void ChangeClientIDNullThrows() { Assert.Throws <NullReferenceException>(() => UnityDataHolder.changeClientID(null, ts)); Assert.Throws <NullReferenceException>(() => UnityDataHolder.changeClientID(ts, null)); }
public void SetDataNullThrows() { Assert.Throws <NullReferenceException>(() => UnityDataHolder.setString(null, ts)); Assert.Throws <NullReferenceException>(() => UnityDataHolder.setString(ts, null)); }
public void AddClientNullThrows() { Assert.Throws <NullReferenceException>(() => UnityDataHolder.addClient(null)); }
public void SetAndGetString() { UnityDataHolder.setString(ts, ts); Assert.True(UnityDataHolder.getData(ts).Equals(ts)); UnityDataHolder.removeClient(ts); }
public void CanGetData() { Assert.IsNotNull(UnityDataHolder.getData(ts)); }
public void DuplicateClientRemovedDNT() { Assert.DoesNotThrow(() => UnityDataHolder.removeClient(ts)); Assert.DoesNotThrow(() => UnityDataHolder.removeClient(ts)); }
public void DuplicateClientAddedDNT() { Assert.DoesNotThrow(() => UnityDataHolder.addClient(ts)); }
public void TearDown() { UnityDataHolder.removeClient(ts); }
public void Setup() { UnityDataHolder.addClient(ts); }