Exemplo n.º 1
0
        private DeviceModelTelemetryMessageSchemaOverride GetEmptyDeviceModelApiModelTelemetryMessageSchemaOverride()
        {
            var messageSchemaOverride = new DeviceModelTelemetryMessageSchemaOverride()
            {
                Name   = "",
                Format = "",
                Fields = new Dictionary <string, string>()
            };

            return(messageSchemaOverride);
        }
Exemplo n.º 2
0
        public void ItReturnsDeviceModelApiModelTelemetryMessageSchemaOverrideFromServiceModel()
        {
            // Arrange
            var messageSchemaOverride = this.GetMessageSchemaOverride();

            // Act
            var result = DeviceModelTelemetryMessageSchemaOverride.FromServiceModel(messageSchemaOverride);

            // Assert
            Assert.IsType <DeviceModelTelemetryMessageSchemaOverride>(result);
        }
Exemplo n.º 3
0
        private DeviceModelTelemetryMessageSchemaOverride GetDeviceModelApiModelTelemetryMessageSchemaOverride()
        {
            var messageSchemaOverride = new DeviceModelTelemetryMessageSchemaOverride()
            {
                Name   = "chiller",
                Format = "JSON",
                Fields = new Dictionary <string, string>()
                {
                    { "cargotemperature", "Double" }
                }
            };

            return(messageSchemaOverride);
        }
 public DeviceModelTelemetryOverride()
 {
     this.Interval        = null;
     this.MessageTemplate = null;
     this.MessageSchema   = null;
 }