Skip to content

Commit

Permalink
Black test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
cmalinmayor committed May 16, 2024
1 parent 7d57f92 commit a2cdf71
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
16 changes: 9 additions & 7 deletions tests/cases/csv_points_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,10 @@
GraphSpec,
build,
Coordinate,
Roi
Roi,
)


# automatically set the seed for all tests
@pytest.fixture(autouse=True)
def seeds():
Expand Down Expand Up @@ -53,7 +54,10 @@ def test_pipeline3(test_points):
csv_source = CsvPointsSource(
fake_points_file,
points_key,
spatial_cols=[0,1,],
spatial_cols=[
0,
1,
],
delimiter="\t",
points_spec=GraphSpec(roi=Roi(shape=Coordinate((100, 100)), offset=(0, 0))),
)
Expand All @@ -62,14 +66,12 @@ def test_pipeline3(test_points):
shape = Coordinate((100, 100))
request.add(points_key, shape)

pipeline = (
csv_source
)
pipeline = csv_source
with build(pipeline) as b:
request = b.request_batch(request)

target_locs = [list(fake_point) for fake_point in fake_points]
result_points = list(request[points_key].nodes)
result_locs = [list(point.location) for point in result_points]
assert result_locs == unordered(target_locs)

assert result_locs == unordered(target_locs)
5 changes: 4 additions & 1 deletion tests/cases/shift_augment.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,10 @@ def test_pipeline3(test_points):
csv_source = CsvPointsSource(
fake_points_file,
points_key,
spatial_cols=[0,1,],
spatial_cols=[
0,
1,
],
delimiter="\t",
points_spec=GraphSpec(roi=Roi(shape=Coordinate((100, 100)), offset=(0, 0))),
)
Expand Down

0 comments on commit a2cdf71

Please sign in to comment.