Skip to content

Commit

Permalink
fix: tests for crossmatch api
Browse files Browse the repository at this point in the history
  • Loading branch information
kristinagalik authored and kubantjan committed May 3, 2023
1 parent dc0f084 commit 3be8976
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions tests/web/test_do_crossmatch_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,18 +154,17 @@ def test_theoretical_and_double_antibodies(self):
'match_type': 'HIGH_RES'}
theoretical_antibody_match = {'hla_antibody': {'code': {'broad': 'DPA2', 'high_res': 'DPA1*02:01', 'split': 'DPA2'},
'cutoff': 2000,
'mfi': 2000,
'raw_code': 'DPA1*02:01',
'mfi': 3000,
'raw_code':
'DPA1*02:01',
'second_code': None,
'second_raw_code': None,
'type': 'THEORETICAL'},
'match_type': 'THEORETICAL'}
self.assertEqual(
[double_antibody_match],
res.json['hla_to_antibody'][1]['antibody_matches'])
self.assertEqual(
[double_antibody_match],
res.json['hla_to_antibody'][2]['antibody_matches'])
self.assertEqual(
theoretical_antibody_match,
res.json['hla_to_antibody'][3]['antibody_matches'][1])
print(res.json['hla_to_antibody'][3]['antibody_matches'])
self.assertTrue(
double_antibody_match in res.json['hla_to_antibody'][1]['antibody_matches'])
self.assertTrue(
double_antibody_match in res.json['hla_to_antibody'][2]['antibody_matches'])
self.assertTrue(
theoretical_antibody_match in res.json['hla_to_antibody'][3]['antibody_matches'])

0 comments on commit 3be8976

Please sign in to comment.