Skip to content

Commit

Permalink
Point to correct test case file for generated tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
dillof committed Apr 19, 2024
1 parent fe73d78 commit 108a0b7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ else()
endif()

find_program(NIHTEST nihtest)
set(NIHTEST_REQUIRED_VERSION "1.5")
set(NIHTEST_REQUIRED_VERSION "1.7")

if(RUN_REGRESS)
if (NOT NIHTEST OR NOT PYTHONBIN)
Expand Down
2 changes: 2 additions & 0 deletions regress/convert_to_dir_variant.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@

def create_zip_version(name):
"""Create zip version of test case."""
file_name = name
with open(name, 'r', encoding='utf-8') as input_file:
last_slash = name.rfind('/')
if last_slash != -1:
name = name[last_slash+1:]
last_dot = name.rfind('.')
output_name = name[:last_dot] + '.zip.test'
with open(output_name, 'w', encoding='utf-8') as output_file:
print(f"test-case-source {file_name}", file=output_file)
for line in input_file.readlines():
if line.startswith('<dir>'):
continue
Expand Down

0 comments on commit 108a0b7

Please sign in to comment.