Clean tcp tests (#41673)

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
This commit is contained in:
Julian Engelhardt 2021-01-27 22:37:59 +01:00 committed by GitHub
parent 0338f5bccf
commit 3f948e027a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 170 additions and 254 deletions

View file

@ -78,10 +78,7 @@ class TcpSensor(Entity):
@property
def name(self):
"""Return the name of this sensor."""
name = self._config[CONF_NAME]
if name is not None:
return name
return super().name
return self._config[CONF_NAME]
@property
def state(self):