Skip to content

Commit

Permalink
Modify run_test.py
Browse files Browse the repository at this point in the history
  • Loading branch information
yqiqichen committed Jan 26, 2024
1 parent 5b14d7a commit 3e58735
Show file tree
Hide file tree
Showing 2 changed files with 185 additions and 184 deletions.
7 changes: 4 additions & 3 deletions tests/run_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def delete_columns(two_d_list, col_del):

class TestClass:
path = os.path.join("tests")
command = "AlphaImpute2"
command = "AlphaImpute2 "
test_cases = None
test_file_depend_on_test_cases = None

Expand Down Expand Up @@ -107,7 +107,7 @@ def generate_command(self):
self.command += f"-{key} "

self.command += (
f"-out_file {os.path.join(self.output_path, self.output_file_prefix)}"
f"-out {os.path.join(self.output_path, self.output_file_prefix)}"
)

def prepare_path(self):
Expand Down Expand Up @@ -150,11 +150,12 @@ def test_one(self):
self.output_file_to_check = "genotypes"

self.generate_command()
print(self.command)
os.system(self.command)

self.output_file_path = os.path.join(
self.output_path,
f"{self.output_file_prefix}.{self.output_file_to_check}.txt",
f"{self.output_file_prefix}.{self.output_file_to_check}",
)
self.expected_file_path = os.path.join(
self.path, f"true_{self.output_file_to_check}.txt"
Expand Down
Loading

0 comments on commit 3e58735

Please sign in to comment.