@@ -24,14 +24,23 @@ def test_cox1_and_co1():
24
24
assert len (sample_changes ) == 2
25
25
26
26
sample1_changes = sample_changes ["sample1" ]
27
- assert len (sample1_changes ) == 1
28
- assert sample1_changes .iloc [0 ]["action" ] == "copy"
29
- assert sample1_changes .iloc [0 ]["symbol" ] == "COX1"
30
- assert sample1_changes .iloc [0 ]["new" ] == "MT-CO1"
27
+ assert len (sample1_changes ) == 0
31
28
32
29
sample2_changes = sample_changes ["sample2" ]
33
30
assert len (sample2_changes ) == 1
34
- assert sample2_changes .iloc [0 ]["action" ] == "conflict"
31
+ assert sample2_changes .iloc [0 ]["action" ] == "rename"
32
+
33
+
34
+ def test_cox1_co1_and_ptgs1 ():
35
+ sample_symbols = {"sample1" : ["MT-CO1" ], "sample2" : ["COX1" , "PTGS1" ]}
36
+ _ , sample_changes = get_changes (sample_symbols )
37
+
38
+ assert len (sample_changes ) == 2
39
+ assert len (sample_changes ["sample1" ]) == 0
40
+ assert len (sample_changes ["sample2" ]) == 1
41
+ assert sample_changes ["sample2" ].iloc [0 ]["action" ] == "rename"
42
+ assert sample_changes ["sample2" ].iloc [0 ]["symbol" ] == "COX1"
43
+ assert sample_changes ["sample2" ].iloc [0 ]["new" ] == "MT-CO1"
35
44
36
45
37
46
def test_single_sample ():
@@ -88,14 +97,11 @@ def test_cox2_and_co2():
88
97
assert len (sample_changes ) == 2
89
98
90
99
sample1_changes = sample_changes ["sample1" ]
91
- assert len (sample1_changes ) == 1
92
- assert sample1_changes .iloc [0 ]["action" ] == "copy"
93
- assert sample1_changes .iloc [0 ]["symbol" ] == "COX2"
94
- assert sample1_changes .iloc [0 ]["new" ] == "MT-CO2"
100
+ assert len (sample1_changes ) == 0
95
101
96
102
sample2_changes = sample_changes ["sample2" ]
97
103
assert len (sample2_changes ) == 1
98
- assert sample2_changes .iloc [0 ]["action" ] == "conflict "
104
+ assert sample2_changes .iloc [0 ]["action" ] == "rename "
99
105
100
106
101
107
def test_cox3 ():
@@ -114,15 +120,15 @@ def test_cox3():
114
120
assert len (sample2_changes ) == 0
115
121
116
122
117
- def test_cox3_and_co1 ():
123
+ def test_cox3_and_co3 ():
118
124
sample_symbols = {"sample1" : ["COX3" ], "sample2" : ["MT-CO3" , "COX3" ]}
119
125
120
126
_ , sample_changes = get_changes (sample_symbols )
121
127
assert len (sample_changes ) == 2
122
128
123
129
sample1_changes = sample_changes ["sample1" ]
124
130
assert len (sample1_changes ) == 1
125
- assert sample1_changes .iloc [0 ]["action" ] == "copy "
131
+ assert sample1_changes .iloc [0 ]["action" ] == "rename "
126
132
assert sample1_changes .iloc [0 ]["symbol" ] == "COX3"
127
133
assert sample1_changes .iloc [0 ]["new" ] == "MT-CO3"
128
134
0 commit comments