public GetDeviceBySerialExecutorTests() { var loggerFactory = new LoggerFactory().AddSerilog(SerilogExtensions.Configure("VSS.Project.WebApi.log")); var serviceCollection = new ServiceCollection(); serviceCollection.AddLogging(); serviceCollection.AddSingleton(loggerFactory); serviceCollection .AddSingleton <IConfigurationStore, GenericConfiguration>() .AddTransient <IServiceExceptionHandler, ServiceExceptionHandler>() .AddTransient <IErrorCodesProvider, ProjectErrorCodesProvider>(); ServiceProvider = serviceCollection.BuildServiceProvider(); _serviceExceptionHandler = ServiceProvider.GetRequiredService <IServiceExceptionHandler>(); _configStore = ServiceProvider.GetRequiredService <IConfigurationStore>(); _logger = ServiceProvider.GetRequiredService <ILoggerFactory>(); _serviceExceptionHandler = ServiceProvider.GetRequiredService <IServiceExceptionHandler>(); _customHeaders = new HeaderDictionary(); _customerUid = Guid.NewGuid().ToString(); _deviceUid = Guid.NewGuid().ToString(); _deviceName = "the Device Name"; _serialNumber = "67567576SN"; _relationStatus = RelationStatusEnum.Active; _tccDeviceStatus = TCCDeviceStatusEnum.Registered; }
public DeviceData(string customerUid, string deviceUid, string deviceName, string serialNumber, RelationStatusEnum relationStatus, TCCDeviceStatusEnum tccDeviceStatus, long?shortRaptorAssetId) { CustomerUID = customerUid; DeviceUID = deviceUid; DeviceName = deviceName; SerialNumber = serialNumber; RelationStatus = relationStatus; TccDeviceStatus = tccDeviceStatus; ShortRaptorAssetId = shortRaptorAssetId; }