Skip to content

Commit

Permalink
[pre-commit.ci] pre-commit autoupdate (#553)
Browse files Browse the repository at this point in the history
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.9.3 → v0.9.4](astral-sh/ruff-pre-commit@v0.9.3...v0.9.4)
- [github.com/psf/black: 24.10.0 → 25.1.0](psf/black@24.10.0...25.1.0)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
pre-commit-ci[bot] authored Feb 3, 2025
1 parent 315d9fd commit a397bda
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,14 +66,14 @@ repos:
args: [--py310-plus]

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.9.3
rev: v0.9.4
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]

# Last modifier: Coding Standard
- repo: https://github.com/psf/black
rev: 24.10.0
rev: 25.1.0
hooks:
- id: black

Expand Down
8 changes: 4 additions & 4 deletions tests/test_macho_bindinghelper.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,14 +134,14 @@ def test_check_address_bounds(self):
class TestLEB(unittest.TestCase):
def test_read_uleb(self):
# Test vector from wikipedia https://en.wikipedia.org/wiki/LEB128
buffer = b"\xE5\x8E\x26"
buffer = b"\xe5\x8e\x26"
expected = (624485, 3)
result = read_uleb(buffer, 0)
self.assertEqual(expected, result)

def test_read_sleb(self):
# Test vector from wikipedia https://en.wikipedia.org/wiki/LEB128
buffer = b"\xE5\x8E\x26"
buffer = b"\xe5\x8e\x26"
expected = (624485, 3)
result = read_sleb(buffer, 0)
self.assertEqual(expected, result)
Expand Down Expand Up @@ -211,7 +211,7 @@ def n_opcode_set_dylib_ordinal_uleb_helper(self, blob, expected):
self.assertEqual(s.lib_ord, expected)

def test_n_opcode_set_dylib_ordinal_uleb(self):
self.n_opcode_set_dylib_ordinal_uleb_helper(b"\xE5\x8E\x26", 624485)
self.n_opcode_set_dylib_ordinal_uleb_helper(b"\xe5\x8e\x26", 624485)
self.n_opcode_set_dylib_ordinal_uleb_helper(b"\x00\x00", 0)
self.n_opcode_set_dylib_ordinal_uleb_helper(b"\x11\x00", 17)

Expand Down Expand Up @@ -276,7 +276,7 @@ def n_opcode_set_addend_sleb_helper(self, blob, expected):
def test_n_opcode_set_addend_sleb(self):
self.n_opcode_set_addend_sleb_helper(b"\x00\x00\x00", 0)
self.n_opcode_set_addend_sleb_helper(b"\x15\x15\x15", 21)
self.n_opcode_set_addend_sleb_helper(b"\xFF\x1F\xEE", 4095)
self.n_opcode_set_addend_sleb_helper(b"\xff\x1f\xee", 4095)

def test_n_opcode_set_segment_and_offset_uleb(self):
BindingState(is_64=True)
Expand Down

0 comments on commit a397bda

Please sign in to comment.