|
1 | 1 | import csv
|
2 | 2 | import logging
|
3 |
| -import os |
4 |
| -import pathlib |
5 |
| -from typing import List |
6 |
| - |
7 |
| -import pytest |
8 | 3 |
|
9 | 4 | from matching.mentor import Mentor
|
10 |
| -from matching.person import Person |
11 | 5 | from matching.process import (
|
12 | 6 | create_participant_list_from_path,
|
13 | 7 | Mentee,
|
@@ -57,37 +51,6 @@ def test_conduct_matching_with_unbalanced_inputs(self, test_data_path, known_fil
|
57 | 51 | )
|
58 | 52 | assert all(every_mentee_has_a_mentor)
|
59 | 53 |
|
60 |
| - @pytest.mark.skipif( |
61 |
| - os.environ.get("TEST") is None, reason="can't put integration data on Github" |
62 |
| - ) |
63 |
| - def test_integration_data(self): |
64 |
| - def _unmatchables(list_participants: List[Person]): |
65 |
| - return len( |
66 |
| - [ |
67 |
| - participant |
68 |
| - for participant in list_participants |
69 |
| - if participant.has_no_match and len(participant.connections) == 0 |
70 |
| - ] |
71 |
| - ) |
72 |
| - |
73 |
| - mentors, mentees = conduct_matching_from_file( |
74 |
| - pathlib.Path(".").absolute() / "integration" |
75 |
| - ) |
76 |
| - every_mentee_has_a_mentor = list( |
77 |
| - map(lambda mentee: len(mentee.mentors) > 0, mentees) |
78 |
| - ) |
79 |
| - logging.info( |
80 |
| - f"Mentees without a mentor: {every_mentee_has_a_mentor.count(False)}\n" |
81 |
| - f"Mentors without any mentees {list(map(lambda mentor: len(mentor.mentees) > 0, mentors)).count(False)}" |
82 |
| - ) |
83 |
| - logging.info( |
84 |
| - f"Total matches made: {sum(map(lambda participant: len(participant.connections), mentees))}" |
85 |
| - ) |
86 |
| - logging.info( |
87 |
| - f"Unmatchable mentors: {_unmatchables(mentors)} | mentees: {_unmatchables(mentees)}" |
88 |
| - ) |
89 |
| - assert all(every_mentee_has_a_mentor) |
90 |
| - |
91 | 54 | def test_create_mailing_list(self, tmp_path, base_mentee, base_mentor, base_data):
|
92 | 55 | mentors = [base_mentor]
|
93 | 56 | for mentor in mentors:
|
|
0 commit comments