| skipped 43 lines |
44 | 44 | | input_queue, output_queue = queues |
45 | 45 | | worker.PROGRESS_BAR = ProgressBar() |
46 | 46 | | worker.CHECK_PROGRESS = worker.PROGRESS_BAR.add_task("Check", total=1) |
47 | | - | worker.BRUTE_PROGRESS = worker.PROGRESS_BAR.add_task("Brute", total=0) |
48 | 47 | | check_task = worker.PROGRESS_BAR.tasks[worker.CHECK_PROGRESS] |
49 | | - | brute_task = worker.PROGRESS_BAR.tasks[worker.BRUTE_PROGRESS] |
50 | 48 | | |
51 | 49 | | _attack_route_bad = lambda t: False |
52 | 50 | | monkeypatch.setattr(worker, "attack_route", _attack_route_bad) |
| skipped 3 lines |
56 | 54 | | assert output_queue.qsize() == 0 |
57 | 55 | | assert check_task.finished |
58 | 56 | | assert check_task.remaining == 0 |
59 | | - | assert brute_task.finished |
60 | | - | assert brute_task.remaining == 0 |
61 | 57 | | |
62 | 58 | | |
63 | 59 | | class TestBruteCredentials: |
| skipped 21 lines |
85 | 81 | | input_queue, output_queue = queues |
86 | 82 | | worker.PROGRESS_BAR = ProgressBar() |
87 | 83 | | worker.BRUTE_PROGRESS = worker.PROGRESS_BAR.add_task("Brute", total=1) |
88 | | - | worker.SCREENSHOT_PROGRESS = worker.PROGRESS_BAR.add_task("Screenshot", total=0) |
89 | 84 | | brute_task = worker.PROGRESS_BAR.tasks[worker.BRUTE_PROGRESS] |
90 | | - | screenshot_task = worker.PROGRESS_BAR.tasks[worker.SCREENSHOT_PROGRESS] |
91 | 85 | | |
92 | 86 | | _attack_credentials_bad = lambda t: False |
93 | 87 | | monkeypatch.setattr(worker, "attack_credentials", _attack_credentials_bad) |
| skipped 3 lines |
97 | 91 | | assert output_queue.qsize() == 0 |
98 | 92 | | assert brute_task.finished |
99 | 93 | | assert brute_task.remaining == 0 |
100 | | - | assert screenshot_task.finished |
101 | | - | assert screenshot_task.remaining == 0 |
102 | 94 | | |
103 | 95 | | |
104 | 96 | | class TestScreenshotTargets: |
| skipped 34 lines |