Skip to content

Commit

Permalink
format etc
Browse files Browse the repository at this point in the history
  • Loading branch information
ctb committed Nov 10, 2024
1 parent b85caf2 commit 621ac03
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
4 changes: 3 additions & 1 deletion src/manysearch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,9 @@ pub fn manysearch(
let against_name = against_sig.name();
let against_md5 = against_sig.md5sum();

if let Ok(against_mh) = <SigStore as TryInto<KmerMinHash>>::try_into(against_sig) {
if let Ok(against_mh) =
<SigStore as TryInto<KmerMinHash>>::try_into(against_sig)
{
for query in query_sketchlist.iter() {
// avoid calculating details unless there is overlap

Expand Down
2 changes: 1 addition & 1 deletion src/python/tests/test_manysearch.py
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ def test_simple_scaled(runtmp, indexed, zip_query):

df = pandas.read_csv(output)
assert len(df) == 3
assert set(list(df['scaled'])) == {10000}
assert set(list(df["scaled"])) == {10000}


def test_simple_manifest(runtmp, indexed):
Expand Down
7 changes: 5 additions & 2 deletions src/python/tests/test_multisearch.py
Original file line number Diff line number Diff line change
Expand Up @@ -1195,11 +1195,14 @@ def test_mismatched_scaled_query(runtmp):

output = runtmp.output("out.csv")

runtmp.sourmash("scripts", "multisearch", query_list, against_list, "-o", output, '-s', '10_000')
runtmp.sourmash(
"scripts", "multisearch", query_list, against_list, "-o", output, "-s", "10_000"
)
assert os.path.exists(output)
df = pandas.read_csv(output)
assert len(df) == 5
assert set(list(df['scaled'])) == {10_000}
assert set(list(df["scaled"])) == {10_000}


def test_mismatched_scaled_against(runtmp):
# test what happens if against scaled is too high
Expand Down
6 changes: 2 additions & 4 deletions src/python/tests/test_pairwise.py
Original file line number Diff line number Diff line change
Expand Up @@ -743,10 +743,8 @@ def test_simple_scaled(runtmp):

output = runtmp.output("out.csv")

runtmp.sourmash(
"scripts", "pairwise", query_list, "-o", output, "-s", "10_000"
)
runtmp.sourmash("scripts", "pairwise", query_list, "-o", output, "-s", "10_000")
assert os.path.exists(output)
df = pandas.read_csv(output)
assert len(df) == 1
assert set(list(df['scaled'])) == {10_000}
assert set(list(df["scaled"])) == {10_000}

0 comments on commit 621ac03

Please sign in to comment.