@@ -56,7 +56,7 @@ async def test_configure_service_with_field(
5656 {
5757 "name" : "Test" ,
5858 "state" : {"reachable" : True },
59- "type" : "Light " ,
59+ "type" : "Dimmable light " ,
6060 "uniqueid" : "00:00:00:00:00:00:00:01-00" ,
6161 }
6262 ],
@@ -85,7 +85,7 @@ async def test_configure_service_with_entity(
8585 {
8686 "name" : "Test" ,
8787 "state" : {"reachable" : True },
88- "type" : "Light " ,
88+ "type" : "Dimmable light " ,
8989 "uniqueid" : "00:00:00:00:00:00:00:01-00" ,
9090 }
9191 ],
@@ -204,7 +204,7 @@ async def test_service_refresh_devices(
204204 "1" : {
205205 "name" : "Light 1 name" ,
206206 "state" : {"reachable" : True },
207- "type" : "Light " ,
207+ "type" : "Dimmable light " ,
208208 "uniqueid" : "00:00:00:00:00:00:00:01-00" ,
209209 }
210210 },
@@ -270,7 +270,7 @@ async def test_service_refresh_devices_trigger_no_state_update(
270270 "1" : {
271271 "name" : "Light 1 name" ,
272272 "state" : {"reachable" : True },
273- "type" : "Light " ,
273+ "type" : "Dimmable light " ,
274274 "uniqueid" : "00:00:00:00:00:00:00:01-00" ,
275275 }
276276 },
@@ -301,7 +301,7 @@ async def test_service_refresh_devices_trigger_no_state_update(
301301 {
302302 "name" : "Light 0 name" ,
303303 "state" : {"reachable" : True },
304- "type" : "Light " ,
304+ "type" : "Dimmable light " ,
305305 "uniqueid" : "00:00:00:00:00:00:00:01-00" ,
306306 }
307307 ],
@@ -327,7 +327,12 @@ async def test_remove_orphaned_entries_service(
327327 """Test service works and also don't remove more than expected."""
328328 device = device_registry .async_get_or_create (
329329 config_entry_id = config_entry_setup .entry_id ,
330- connections = {(dr .CONNECTION_NETWORK_MAC , "123" )},
330+ identifiers = {(DOMAIN , BRIDGE_ID )},
331+ )
332+
333+ device_registry .async_get_or_create (
334+ config_entry_id = config_entry_setup .entry_id ,
335+ identifiers = {(DOMAIN , "orphaned" )},
331336 )
332337
333338 assert (
@@ -338,7 +343,7 @@ async def test_remove_orphaned_entries_service(
338343 if config_entry_setup .entry_id in entry .config_entries
339344 ]
340345 )
341- == 5 # Host, gateway , light, switch and orphan
346+ == 4 # Gateway , light, switch and orphan
342347 )
343348
344349 entity_registry .async_get_or_create (
@@ -374,7 +379,7 @@ async def test_remove_orphaned_entries_service(
374379 if config_entry_setup .entry_id in entry .config_entries
375380 ]
376381 )
377- == 4 # Host, gateway , light and switch
382+ == 3 # Gateway , light and switch
378383 )
379384
380385 assert (
0 commit comments