Skip to content

Commit f92156b

Browse files
authored
Install codespell, and correct spell errors. (#846)
1 parent 37fb268 commit f92156b

File tree

11 files changed

+20
-13
lines changed

11 files changed

+20
-13
lines changed

TODO_add_checks

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
1) add .pre-commit and commit-hook
22

33
2) new checks
4-
- codespell
54
- flake8 addons:
65
pycodestyle
76
pyflakes

doc/INSTALL

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ The API documents can be generated using one of four programs:
6262
* pydoctor
6363
* doxygen
6464

65-
To bulid these, simply run the following command and the available
65+
To build these, simply run the following command and the available
6666
packages will sipmly be built::
6767

6868
python setup.py build_apidocs

doc/api/epydoc/build.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,4 @@
3737
shutil.move("html", "../../../build/epydoc")
3838
except Exception: # pylint: disable=broad-except
3939
traceback.print_exc(file=sys.stdout)
40-
print( "Epydoc not avaliable...not building")
40+
print( "Epydoc not available...not building")

requirements-checks.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
flake8 >= 2.6.0
33
flake8-docstrings >= 0.2.8
44
pyflakes >= 1.2.3
5-
pylint >=2.13.3
5+
pylint >= 2.13.3
6+
codespell >= 2.1.0

test/test_datastore.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ def test_modbus_sparse_data_block(self):
118118
block = ModbusSparseDataBlock()
119119
self.assertEqual(block.values, {})
120120

121-
# mark block as unmutable and see if parameter exeception
121+
# mark block as unmutable and see if parameter exception
122122
# is raised for invalid offset writes
123123
block = ModbusSparseDataBlock({1: 100}, mutable=False)
124124
self.assertRaises(ParameterException, block.setValues, 0, 1)
@@ -403,7 +403,7 @@ def test_set(self):
403403
)
404404

405405
def test_update_success(self):
406-
""" Test update succcess. """
406+
""" Test update success. """
407407
self.slave._connection.execute = MagicMock( # pylint: disable=protected-access
408408
return_value=MockSqlResult(rowcount=len(self.mock_values))
409409
)

test/test_device.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ def test_modbus_control_block_counters(self):
165165
self.assertEqual(0, self.control.Counter.SlaveMessage)
166166

167167
def test_modbus_control_block_update(self):
168-
""" Tests the MCB counters upate methods """
168+
""" Tests the MCB counters update methods """
169169
values = {'SlaveMessage':5, 'BusMessage':5}
170170
self.control.Counter.BusMessage += 1
171171
self.control.Counter.SlaveMessage += 1

test/test_exceptions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def setUp(self):
1818
self.exceptions = [
1919
ModbusException("bad base"),
2020
ModbusIOException("bad register"),
21-
ParameterException("bad paramater"),
21+
ParameterException("bad parameter"),
2222
NotImplementedException("bad function"),
2323
ConnectionException("bad connection"),
2424
]

test/test_other_messages.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env python3
2-
""" Test other messsages. """
2+
""" Test other messages. """
33
import unittest
44
import mock
55

@@ -30,7 +30,7 @@ def tearDown(self):
3030
del self.responses
3131

3232
def test_other_messages_to_string(self):
33-
""" Test other messsages to string. """
33+
""" Test other messages to string. """
3434
for message in self.requests:
3535
self.assertNotEqual(str(message()), None)
3636
for message in self.responses:

test/test_pdu.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def tearDown(self):
3131
del self.exception
3232

3333
def test_not_impelmented(self):
34-
""" Test a base classes for not implemented funtions """
34+
""" Test a base classes for not implemented functions """
3535
for request in self.bad_requests:
3636
self.assertRaises(NotImplementedException, request.encode)
3737

test/test_server_async.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def test_connection_lost(self): # pylint: disable=no-self-use
7676
def test_data_received(self):
7777
""" Test data received. """
7878
protocol = ModbusTcpProtocol()
79-
# mock_data = "Hellow world!"
79+
# mock_data = "Hello world!"
8080
mock_data = b"\x00\x01\x12\x34\x00\x04\xff\x02\x12\x34"
8181
protocol.factory = MagicMock()
8282
protocol.factory.control.ListenOnly = False

0 commit comments

Comments
 (0)