public async Task GenerateRandomIdentifierForDevice_ReturnsIdentifier()
        {
            // arrange

            // act
            var res = await _service.GenerateRandomIdentifierForDeviceAsync(1);

            // assert
            Assert.True(res == "id1" || res == "id2" || res == "id3");
        }
        public async Task GenerateRandomIdentifierForDevice_DontReturnDeviceName()
        {
            var ids = new List <string> {
                "id1", "id2", "id3", "id4"
            };
            var mockedAccessor = new Mock <IIdentifierDictionaryFileAccessor>();

            mockedAccessor.Setup(x => x.ListIdentifiers(It.IsAny <string>())).Returns(ids);
            await SeedDefaultIdentifiers();

            var service = new MqttEntityIdentifierSuggestionService(_identifierService, mockedAccessor.Object, _dbContext);

            _dbContext.Devices.Add(new Device {
                Name = "id1", NormalizedName = Device.NormalizeName("id1")
            });
            await _dbContext.SaveChangesAsync();

            var res = await service.GenerateRandomIdentifierForDeviceAsync(1);

            Assert.True(res != "id1" && ids.Contains(res));
        }