From: Melissa LeBlanc-Williams Date: Thu, 10 Sep 2020 23:45:11 +0000 (-0700) Subject: Black formatted X-Git-Tag: 5.4.0^2~2 X-Git-Url: https://git.ayoreis.com/Adafruit_Blinka-hackapet.git/commitdiff_plain/de082d32a6a103f50b65b072250b127a94113a6d Black formatted --- diff --git a/src/adafruit_blinka/__init__.py b/src/adafruit_blinka/__init__.py index 2df8a2d..69e9178 100755 --- a/src/adafruit_blinka/__init__.py +++ b/src/adafruit_blinka/__init__.py @@ -8,8 +8,8 @@ class Enum: """ - Object supporting CircuitPython-style of static symbols - as seen with Direction.OUTPUT, Pull.UP + Object supporting CircuitPython-style of static symbols + as seen with Direction.OUTPUT, Pull.UP """ def __repr__(self): @@ -27,8 +27,8 @@ class Enum: @classmethod def iteritems(cls): """ - Inspects attributes of the class for instances of the class - and returns as key,value pairs mirroring dict#iteritems + Inspects attributes of the class for instances of the class + and returns as key,value pairs mirroring dict#iteritems """ for key in dir(cls): val = getattr(cls, key) diff --git a/src/adafruit_blinka/microcontroller/stm32/stm32mp157/pin.py b/src/adafruit_blinka/microcontroller/stm32/stm32mp157/pin.py index d5c8810..0196982 100755 --- a/src/adafruit_blinka/microcontroller/stm32/stm32mp157/pin.py +++ b/src/adafruit_blinka/microcontroller/stm32/stm32mp157/pin.py @@ -145,9 +145,7 @@ PZ6 = Pin((9, 6)) PZ7 = Pin((9, 7)) # ordered as uartId, txId, rxId -UART_PORTS = ( - (3, PB10, PB12), -) +UART_PORTS = ((3, PB10, PB12),) # ordered as i2cId, sclId, sdaId I2C_PORTS = ( diff --git a/src/busio.py b/src/busio.py index d63c815..1cad051 100755 --- a/src/busio.py +++ b/src/busio.py @@ -127,7 +127,7 @@ class I2C(Lockable): in_end=None, stop=False ): - """"Write to a device at specified address from a buffer then read + """ "Write to a device at specified address from a buffer then read from a device at specified address into a buffer """ return self._i2c.writeto_then_readfrom( diff --git a/test/src/testing/adafruit_blinka.py b/test/src/testing/adafruit_blinka.py index 5ad38e2..3fcecc3 100644 --- a/test/src/testing/adafruit_blinka.py +++ b/test/src/testing/adafruit_blinka.py @@ -3,8 +3,8 @@ import unittest class TestEnum(unittest.TestCase): """ - Verifies the repl() and str() behaviour of an example Enum - Enums represent configuration values such as digitalio.Direction, digitalio.Pull etc. + Verifies the repl() and str() behaviour of an example Enum + Enums represent configuration values such as digitalio.Direction, digitalio.Pull etc. """ def setUp(self): @@ -24,7 +24,13 @@ class TestEnum(unittest.TestCase): def test_iteritems(self): """A subtype of Enum can list all attributes of its own type""" items = list(self.Cls.iteritems()) - self.assertEqual(items, [("one", self.Cls.one), ("two", self.Cls.two),]) + self.assertEqual( + items, + [ + ("one", self.Cls.one), + ("two", self.Cls.two), + ], + ) def test_repr(self): """A repr() call on an Enum gives its fully-qualified name"""