Skip to content

Commit 8f317a7

Browse files
author
James Boulton
committed
Bug tidy
1 parent 2b90cde commit 8f317a7

File tree

7 files changed

+7
-2
lines changed

7 files changed

+7
-2
lines changed

dashio/dashconnection.py

+1
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
from .constants import CONNECTION_PUB_URL
3535
from .iotcontrol.enums import ConnectionState
3636

37+
3738
class DashControl():
3839
"""Class to stare dash connection info
3940
"""

dashio/iotcontrol/button.py

+1
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ def from_dict(cls, cfg_dict: dict):
7777
tmp_cls.parent_id = cfg_dict["parentID"]
7878
return tmp_cls
7979

80+
8081
class Button(Control):
8182
"""A Button control.
8283

dashio/iotcontrol/control.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
SOFTWARE.
2323
"""
2424
import json
25-
import logging
25+
2626
from ..constants import BAD_CHARS
2727
from .enums import ColorPickerStyle, DeviceViewStyle, DialNumberPosition, DirectionStyle, ChartXAxisLabelsStyle,\
2828
Keyboard, KnobStyle, Precision, TextAlignment, TitlePosition, Icon, Color, TextFormat, LabelStyle, SliderBarStyle,\

dashio/iotcontrol/event_log.py

+1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
from .ring_buffer import RingBuffer
3131
from .event import Event
3232

33+
3334
class EventData:
3435
"""Event log data point
3536
"""

dashio/iotcontrol/map.py

+1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
from .enums import TitlePosition, Color
3131
from .event import Event
3232

33+
3334
class MapLocation:
3435
"""
3536
A json version of a map location.

dashio/mqttconnection.py

+1
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535

3636
from .iotcontrol.enums import ConnectionState
3737

38+
3839
class MQTTConnection(threading.Thread):
3940
"""Setups and manages a connection thread to the MQTT Server."""
4041

tests/test_button.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def test_button_set_text(self):
3737
def test_button_text_icon(self):
3838
test_control = Button("BUTTONID")
3939
test_control.send_button(ButtonState.ON, Icon.SQUARE, "HELLO")
40-
self.assertEqual(test_control.get_state(), '\t{device_id}\tBTTN\tBUTTONID\tON\tPad\tHELLO\n', "icon Should be Pad")
40+
self.assertEqual(test_control.get_state(), '\t{device_id}\tBTTN\tBUTTONID\tON\tSquare\tHELLO\n', "icon Should be Square")
4141

4242

4343
if __name__ == '__main__':

0 commit comments

Comments
 (0)