Example #1
0
File: Game.cs Project: Corne/VOC
        public Game(string name, ConnectionInfo connectionIno)
        {
            if (name == null)
                throw new ArgumentNullException(nameof(name));
            if (connectionIno == null)
                throw new ArgumentNullException(nameof(connectionIno));

            Name = name;
            ConnectionInfo = connectionIno;
        }
Example #2
0
 public DummyGame()
 {
     Name = $"Game: {Guid.NewGuid()}";
     ConnectionInfo = new ConnectionInfo(new IPAddress(new byte[] { 127, 0, 0, 1 }), 1337);
 }
Example #3
0
 public void CantBeConstructedWithNull(string name, ConnectionInfo connection)
 {
     Assert.Throws<ArgumentNullException>(() => new Game(name, connection));
 }