Skip to content

Commit

Permalink
add pre commit (#86)
Browse files Browse the repository at this point in the history
- Add .pre-commit config file
- Add formatting to test_affinder
  • Loading branch information
jni authored Nov 27, 2023
1 parent 1a60b60 commit 9eea4e7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
repos:
- repo: https://github.com/google/yapf
rev: 'v0.40.2' # Use the sha / tag you want to point at
hooks:
- id: yapf
exclude: docs/conf.py
6 changes: 1 addition & 5 deletions src/affinder/_tests/test_affinder.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
from scipy import ndimage as ndi
from pathlib import Path


layer0_pts = np.array([[140.38371886,
322.5390704], [181.91866481, 319.65803368],
[176.15659138, 259.1562627],
Expand Down Expand Up @@ -165,7 +164,4 @@ def test_load_affine(tmp_path):
widget = load_affine()
widget(layer, affile)

np.testing.assert_allclose(
layer.affine, affine
)

np.testing.assert_allclose(layer.affine, affine)

0 comments on commit 9eea4e7

Please sign in to comment.