private static void FullTestSensorInfo(string productName, SensorValueBase sensorValue, IsSensorRegistered isSensorRegistered,
                                               GetSensorInfo getSensorInfo, GetProductSensors getProductSensors, GetSensorInfoFromDB getSensorFromDB, SensorValuesTester tester)
        {
            var sensorValuePath = sensorValue.Path;

            Assert.True(isSensorRegistered(productName, sensorValuePath));
            tester.TestSensorInfoFromDB(sensorValue, getSensorInfo(productName, sensorValuePath));
            tester.TestSensorInfoFromDB(sensorValue, getProductSensors(productName).FirstOrDefault(s => s.Path == sensorValuePath));
            tester.TestSensorInfoFromDB(sensorValue, getSensorFromDB(productName, sensorValuePath));
        }
        private static void FullTestRemovedSensor(string productName, SensorValueBase sensorValue,
                                                  IsSensorRegistered isSensorRegistered, GetSensorInfo getSensorInfo, GetProductSensors getProductSensors,
                                                  GetQueueValues getQueueValues, GetAllSensorHistory getAllSensorHistory,
                                                  GetSensorInfoFromDB getSensorFromDB, SensorValuesTester tester)
        {
            string sensorValuePath = sensorValue.Path;

            Assert.False(isSensorRegistered(productName, sensorValuePath));
            Assert.Null(getSensorInfo(productName, sensorValuePath));
            Assert.Null(getProductSensors(productName).FirstOrDefault(s => s.Path == sensorValuePath));
            Assert.Empty(getQueueValues(new List <string>()
            {
                productName
            }));
            Assert.Empty(getAllSensorHistory(productName, sensorValuePath));
            tester.TestSensorInfoFromDB(sensorValue, getSensorFromDB(productName, sensorValuePath));
        }
 private static void FullTestNonExistingSensorInfo(string productName, string sensorPath, IsSensorRegistered isSensorReqistered,
                                                   GetSensorInfo getSensorInfo, GetProductSensors getProductSensors, GetSensorInfoFromDB getSensorInfoFromDB)
 {
     Assert.False(isSensorReqistered(productName, sensorPath));
     Assert.Null(getSensorInfo(productName, sensorPath));
     Assert.Null(getProductSensors(productName)?.FirstOrDefault(s => s.Path == sensorPath));
     Assert.Null(getSensorInfoFromDB(productName, sensorPath));
 }