Skip to content

Commit

Permalink
chore: Resolving merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
ns-rse committed Dec 10, 2024
1 parent a1e6d13 commit 68fdba1
Showing 1 changed file with 0 additions and 314 deletions.
314 changes: 0 additions & 314 deletions tests/test_isoslam.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,163 +93,6 @@ def test_extract_segment_pairs(bam_file: str | Path, expected_length: int) -> No
assert len(list(alignment_file)) == expected_length


<<<<<<< HEAD
<<<<<<< HEAD
@pytest.mark.parametrize(
("aligned_segment1", "aligned_segment2", "expected"),
[
pytest.param( # type: ignore[misc]
"aligned_segment_28584",
"aligned_segment_17416",
{
"read1": {
"start": 28584,
"end": 28733,
"length": 149,
"status": None,
"transcript": None,
"block_start": (28584, 28704),
"block_end": (28704, 28733),
},
"read2": {
"start": 17416,
"end": 17805,
"length": 389,
"status": None,
"transcript": None,
"block_start": (17416, 17718),
"block_end": (17479, 17805),
},
},
id="28584 and 17416 - Assignment and Transcript are None",
),
],
)
def test_extract_features_from_pair(
aligned_segment1: str,
aligned_segment2: str,
expected: dict[str, dict[str, int | None | str | tuple[int, int]]],
request: pytest.FixtureRequest,
) -> None:
"""Test extract of features from a list of pairs."""
read_pair = isoslam.extract_features_from_pair(
[
request.getfixturevalue(aligned_segment1),
request.getfixturevalue(aligned_segment2),
]
)
assert isinstance(read_pair, dict)
assert read_pair == expected
||||||| parent of 3878e7a (fixup! feature(isoslam): Adds functions to extract features from reads)
# @pytest.mark.parametrize(
# ("aligned_segment", "start", "end", "length", "status", "transcript", "block_start", "block_end"),
# [
# pytest.param( # type: ignore[misc]
# "aligned_segment_28584",
# 28584,
# 28733,
# 149,
# None,
# None,
# (28584, 28704),
# (28704, 28733),
# id="28584 - Assignment and Transcript are None",
# ),
# pytest.param(
# "aligned_segment_17416",
# 17416,
# 17805,
# 389,
# "Assigned",
# "Something",
# (17416, 17718),
# (17479, 17805),
# id="17416 - Assignment and Transcript are None",
# marks=pytest.mark.xfail(reasion="Not getting Assigned or Transcript tags for some reason?"),
# ),
# pytest.param(
# "aligned_segment_18029",
# 18029,
# 18385,
# 356,
# "Assigned",
# "something",
# (18029, 18380),
# (18174, 18385),
# id="17416 - Assignment and Transcript are None",
# marks=pytest.mark.xfail(reasion="Not getting Assigned tag for some reason?"),
# ),
# ],
# )
# def test_extract_features_from_read_param(
# aligned_segment: str,
# start: int,
# end: int,
# length: int,
# status: str,
# transcript: str,
# block_start: tuple[int, int],
# block_end: tuple[int, int],
# request: pytest.FixtureRequest,
# ) -> None:
# """Test extract of features from an aligned segment read."""
# segment = isoslam.extract_features_from_read(request.getfixturevalue(aligned_segment))
# assert isinstance(segment, dict)
# assert segment["start"] == start
# assert segment["end"] == end
# assert segment["length"] == length
# assert segment["status"] == status
# assert segment["transcript"] == transcript
# assert segment["block_start"] == block_start
# assert segment["block_end"] == block_end


# @pytest.mark.parametrize(
# ("aligned_segment1", "aligned_segment2", "expected"),
# [
# pytest.param( # type: ignore[misc]
# "aligned_segment_28584",
# "aligned_segment_17416",
# {
# "read1": {
# "start": 28584,
# "end": 28733,
# "length": 149,
# "status": None,
# "transcript": None,
# "block_start": (28584, 28704),
# "block_end": (28704, 28733),
# },
# "read2": {
# "start": 17416,
# "end": 17805,
# "length": 389,
# "status": None,
# "transcript": None,
# jls_extract_var: (17416, 17718),
# "block_end": (17479, 17805),
# },
# },
# id="28584 and 17416 - Assignment and Transcript are None",
# ),
# ],
# )
# def test_extract_features_from_pair(
# aligned_segment1: str,
# aligned_segment2: str,
# expected: dict[str, dict[str, int | None | str | tuple[int, int]]],
# request: pytest.FixtureRequest,
# ) -> None:
# """Test extract of features from a list of pairs."""
# read_pair = isoslam.extract_features_from_pair(
# [
# request.getfixturevalue(aligned_segment1),
# request.getfixturevalue(aligned_segment2),
# ]
# )
# assert isinstance(read_pair, dict)
# assert read_pair == expected
=======
@pytest.mark.parametrize(
("aligned_segment", "start", "end", "length", "status", "transcript", "block_start", "block_end"),
[
Expand Down Expand Up @@ -389,160 +232,3 @@ def test_extract_features_from_pair(
)
assert isinstance(read_pair, dict)
assert read_pair == expected
>>>>>>> 3878e7a (fixup! feature(isoslam): Adds functions to extract features from reads)
||||||| parent of 3ee6aa7 (feature(isoslam): Adds extract_segment_pair() function)
@pytest.mark.parametrize(
("aligned_segment1", "aligned_segment2", "expected"),
[
pytest.param( # type: ignore[misc]
"aligned_segment_28584",
"aligned_segment_17416",
{
"read1": {
"start": 28584,
"end": 28733,
"length": 149,
"status": None,
"transcript": None,
"block_start": (28584, 28704),
"block_end": (28704, 28733),
},
"read2": {
"start": 17416,
"end": 17805,
"length": 389,
"status": None,
"transcript": None,
"block_start": (17416, 17718),
"block_end": (17479, 17805),
},
},
id="28584 and 17416 - Assignment and Transcript are None",
),
],
)
def test_extract_features_from_pair(
aligned_segment1: str,
aligned_segment2: str,
expected: dict[str, dict[str, int | None | str | tuple[int, int]]],
request: pytest.FixtureRequest,
) -> None:
"""Test extract of features from a list of pairs."""
read_pair = isoslam.extract_features_from_pair(
[
request.getfixturevalue(aligned_segment1),
request.getfixturevalue(aligned_segment2),
]
)
assert isinstance(read_pair, dict)
assert read_pair == expected
=======
# @pytest.mark.parametrize(
# ("aligned_segment", "start", "end", "length", "status", "transcript", "block_start", "block_end"),
# [
# pytest.param( # type: ignore[misc]
# "aligned_segment_28584",
# 28584,
# 28733,
# 149,
# None,
# None,
# (28584, 28704),
# (28704, 28733),
# id="28584 - Assignment and Transcript are None",
# ),
# pytest.param(
# "aligned_segment_17416",
# 17416,
# 17805,
# 389,
# "Assigned",
# "Something",
# (17416, 17718),
# (17479, 17805),
# id="17416 - Assignment and Transcript are None",
# marks=pytest.mark.xfail(reasion="Not getting Assigned or Transcript tags for some reason?"),
# ),
# pytest.param(
# "aligned_segment_18029",
# 18029,
# 18385,
# 356,
# "Assigned",
# "something",
# (18029, 18380),
# (18174, 18385),
# id="17416 - Assignment and Transcript are None",
# marks=pytest.mark.xfail(reasion="Not getting Assigned tag for some reason?"),
# ),
# ],
# )
# def test_extract_features_from_read_param(
# aligned_segment: str,
# start: int,
# end: int,
# length: int,
# status: str,
# transcript: str,
# block_start: tuple[int, int],
# block_end: tuple[int, int],
# request: pytest.FixtureRequest,
# ) -> None:
# """Test extract of features from an aligned segment read."""
# segment = isoslam.extract_features_from_read(request.getfixturevalue(aligned_segment))
# assert isinstance(segment, dict)
# assert segment["start"] == start
# assert segment["end"] == end
# assert segment["length"] == length
# assert segment["status"] == status
# assert segment["transcript"] == transcript
# assert segment["block_start"] == block_start
# assert segment["block_end"] == block_end


# @pytest.mark.parametrize(
# ("aligned_segment1", "aligned_segment2", "expected"),
# [
# pytest.param( # type: ignore[misc]
# "aligned_segment_28584",
# "aligned_segment_17416",
# {
# "read1": {
# "start": 28584,
# "end": 28733,
# "length": 149,
# "status": None,
# "transcript": None,
# "block_start": (28584, 28704),
# "block_end": (28704, 28733),
# },
# "read2": {
# "start": 17416,
# "end": 17805,
# "length": 389,
# "status": None,
# "transcript": None,
# jls_extract_var: (17416, 17718),
# "block_end": (17479, 17805),
# },
# },
# id="28584 and 17416 - Assignment and Transcript are None",
# ),
# ],
# )
# def test_extract_features_from_pair(
# aligned_segment1: str,
# aligned_segment2: str,
# expected: dict[str, dict[str, int | None | str | tuple[int, int]]],
# request: pytest.FixtureRequest,
# ) -> None:
# """Test extract of features from a list of pairs."""
# read_pair = isoslam.extract_features_from_pair(
# [
# request.getfixturevalue(aligned_segment1),
# request.getfixturevalue(aligned_segment2),
# ]
# )
# assert isinstance(read_pair, dict)
# assert read_pair == expected
>>>>>>> 3ee6aa7 (feature(isoslam): Adds extract_segment_pair() function)

0 comments on commit 68fdba1

Please sign in to comment.