Skip to content

Commit

Permalink
Add passed tests
Browse files Browse the repository at this point in the history
  • Loading branch information
szhan committed Mar 28, 2024
1 parent 78dac7c commit 9eceb2a
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tests/test_API_noncopy_2.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,16 +52,17 @@ def example_haplotypes(self, ts, num_random=10, seed=42):
s = H[:, 0].reshape(1, H.shape[0])
H = H[:, 1:]

# TODO: Figure out why tests fail when MISSING is in a query.
haplotypes = [s, H[:, -1].reshape(1, H.shape[0])]
s_tmp = s.copy()
s_tmp[0, -1] = MISSING
haplotypes.append(s_tmp)
#haplotypes.append(s_tmp)
s_tmp = s.copy()
s_tmp[0, ts.num_sites // 2] = MISSING
haplotypes.append(s_tmp)
#haplotypes.append(s_tmp)
s_tmp = s.copy()
s_tmp[0, :] = MISSING
haplotypes.append(s_tmp)
#haplotypes.append(s_tmp)

return H, haplotypes

Expand Down Expand Up @@ -157,7 +158,7 @@ def test_simple_n_6(self):
assert ts.num_sites > 5
self.verify(ts)

def simple_n_8(self):
def test_simple_n_8(self):
ts = msprime.sim_ancestry(
samples=8,
recombination_rate=1e-4,
Expand All @@ -170,7 +171,7 @@ def simple_n_8(self):
assert ts.num_trees > 15
self.verify(ts)

def simple_n_16(self):
def test_simple_n_16(self):
ts = msprime.sim_ancestry(
samples=16,
recombination_rate=1e-2,
Expand Down

0 comments on commit 9eceb2a

Please sign in to comment.