Skip to content

Commit

Permalink
tests: Define method rounds depending on python implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
deajan committed Dec 28, 2023
1 parent 016951a commit fcbe8e0
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions tests/test_command_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@
__author__ = 'Orsiris de Jong'
__copyright__ = 'Copyright (C) 2015-2023 Orsiris de Jong'
__licence__ = 'BSD 3 Clause'
__build__ = '2023012101'
__build__ = '2023122801'


import sys
import os
import platform
import re
import threading
import logging
Expand Down Expand Up @@ -284,7 +285,10 @@ def test_read_file():
file_content = file.read()

for method in methods:
for round in range(0, 350):
# pypy is quite slow with poller method on github actions.
# Lets lower rounds
max_rounds = 50 if platform.python_implementation() == 'PyPy' else 1000
for round in range(0, max_rounds):
print('Comparaison round {} with method {}'.format(round, method))
exit_code, output = command_runner(PRINT_FILE_CMD, shell=True, method=method)
if os.name == 'nt':
Expand Down

0 comments on commit fcbe8e0

Please sign in to comment.