Example #1
0
        public void ToNative_WithValidPropertyId_ShouldReturnCorrectValue()
        {
            var id = new PropertyId(1);

            var result = FakeRpcClient.ToNative(id);

            Assert.Equal(1U, result);
        }
Example #2
0
        public void ToNative_WithValidPropertyType_ShouldReturnCorrectValue(PropertyType type, ushort expected)
        {
            var result = FakeRpcClient.ToNative(type);

            Assert.Equal(expected, result);
        }
Example #3
0
 public void ToNative_WithInvalidPropertyType_ShouldThrow()
 {
     Assert.Throws <ArgumentOutOfRangeException>("type", () => FakeRpcClient.ToNative((PropertyType)99));
 }
Example #4
0
 public void ToNative_WithNullPropertyId_ShouldThrow()
 {
     Assert.Throws <ArgumentNullException>("id", () => FakeRpcClient.ToNative(null));
 }
Example #5
0
        public void ToNative_WithValidEcosystem_ShouldReturnCorrectValue(Ecosystem ecosystem, byte expected)
        {
            var result = FakeRpcClient.ToNative(ecosystem);

            Assert.Equal(expected, result);
        }
Example #6
0
 public void ToNative_WithInvalidEcosystem_ShouldThrow()
 {
     Assert.Throws <ArgumentOutOfRangeException>("ecosystem", () => FakeRpcClient.ToNative((Ecosystem)99));
 }