Exemplo n.º 1
0
        public void WorksForValidAddresses(string input, string networkLocation, string networkName, string networkId, string deviceLocation, string deviceName, string deviceId)
        {
            var result = VirtualAddress.Parse(input);

            Assert.That(result.NetworkLocation, Is.EqualTo(networkLocation));
            Assert.That(result.NetworkName, Is.EqualTo(networkName));
            Assert.That(result.NetworkNodeId, Is.EqualTo(networkId));

            Assert.That(result.DeviceLocation, Is.EqualTo(deviceLocation));
            Assert.That(result.DeviceName, Is.EqualTo(deviceName));
            Assert.That(result.DeviceNodeId, Is.EqualTo(deviceId));
        }
Exemplo n.º 2
0
        public void FailsForInvalidAddresses(string input)
        {
            var result = VirtualAddress.Parse(input);

            Assert.That(result, Is.Null);
        }
Exemplo n.º 3
0
 public static VirtualAddress ToVirtualAddress(this IParameter parameter)
 {
     return(VirtualAddress.Parse(parameter.Value));
 }