Skip to content

Commit

Permalink
Remove unnecessary helper function per PR review
Browse files Browse the repository at this point in the history
Signed-off-by: Jonathan Mendez <[email protected]>
  • Loading branch information
jonathanmendez committed Jun 8, 2023
1 parent 29da3db commit b844fdb
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions examples/nidigital_spi/measurement.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,8 @@ def measure(
str(_resolve_relative_path(service_directory, pattern_file_path)),
)

levels_file_name = _get_file_name_from_path(levels_file_path)
timing_file_name = _get_file_name_from_path(timing_file_path)
levels_file_name = pathlib.Path(levels_file_path).stem
timing_file_name = pathlib.Path(timing_file_path).stem
selected_sites.apply_levels_and_timing(levels_file_name, timing_file_name)
selected_sites.burst_pattern(start_label="SPI_Pattern")
site_pass_fail = selected_sites.get_site_pass_fail()
Expand Down Expand Up @@ -157,11 +157,6 @@ def _resolve_relative_path(
return (directory_path / file_path).resolve()


def _get_file_name_from_path(file_path: Union[str, pathlib.PurePath]) -> str:
file_path = pathlib.PurePath(file_path)
return file_path.stem


@click.command
@verbosity_option
@grpc_device_options
Expand Down

0 comments on commit b844fdb

Please sign in to comment.