Skip to content

Commit

Permalink
removed unnecessary sample data generation
Browse files Browse the repository at this point in the history
  • Loading branch information
tclose committed Feb 24, 2024
1 parent eb7e171 commit 0faac56
Showing 1 changed file with 0 additions and 24 deletions.
24 changes: 0 additions & 24 deletions pydra/utils/tests/utils.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from pathlib import Path
import typing as ty
from fileformats.generic import File
from fileformats.core.mixin import WithSeparateHeader, WithMagicNumber
from pydra import mark
Expand All @@ -26,28 +24,6 @@ class MyOtherFormatX(WithMagicNumber, WithSeparateHeader, File):
header_type = MyHeader


@File.generate_sample_data.register
def my_format_x_generate_sample_data(
my_format_x: MyFormatX, dest_dir: Path
) -> ty.List[Path]:
fspath = dest_dir / "file.my"
with open(fspath, "wb") as f:
f.write(b"MYFORMAT\nsome data goes here")
header_fspath = dest_dir / "file.hdr"
header_fspath.write_text("a: 1\nb: 2\nc: 3\n")
return [fspath, header_fspath]


@File.generate_sample_data.register
def my_other_format_generate_sample_data(
my_other_format: MyOtherFormatX, dest_dir: Path
) -> ty.List[Path]:
fspath = dest_dir / "file.my"
with open(fspath, "wb") as f:
f.write(b"MYFORMAT\nsome data goes here")
return [fspath]


@mark.task
def generic_func_task(in_file: File) -> File:
return in_file
Expand Down

0 comments on commit 0faac56

Please sign in to comment.