Skip to content

Commit

Permalink
add pytest coverage #369
Browse files Browse the repository at this point in the history
  • Loading branch information
donaldcampbelljr committed Jul 15, 2024
1 parent d429294 commit b828d9f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/smoketests/test_Sample.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,16 @@ def test_str_repr_correctness(self, example_pep_cfg_path):
assert example_pep_cfg_path in str_repr
assert "Sample '{}'".format(sample["sample_name"]) in str_repr

@pytest.mark.parametrize("example_pep_cfg_path", EXAMPLE_TYPES, indirect=True)
def test_sample_to_yaml_no_path(self, example_pep_cfg_path):
"""
Verify that to_yaml returns representation without requiring a path.
"""
p = Project(cfg=example_pep_cfg_path)
for sample in p.samples:
yaml_repr = sample.to_yaml()
assert "sample_name" in yaml_repr

@pytest.mark.parametrize("example_pep_cfg_path", ["basic"], indirect=True)
def test_sheet_dict_excludes_private_attrs(self, example_pep_cfg_path):
"""
Expand Down

0 comments on commit b828d9f

Please sign in to comment.