<commit_before>#!/usr/bin/env python3

# Copyright (C) 2017 <NAME>
#
# This file is subject to the terms and conditions of the GNU Lesser
# General Public License v2.1. See the file LICENSE in the top level
# directory for more details.

import os
import sys
from testrunner import run


def testfunc(child):
    board = os.environ['BOARD']
    # Increase timeout on "real" hardware
    timeout = 120 if board is not 'native' else -1
    child.expect('OK \(\d+ tests\)', timeout=timeout)


if __name__ == "__main__":
    sys.exit(run(testfunc))<commit_msg>tests/pkg_libcose: increase timeout of autotest<commit_after>#!/usr/bin/env python3

# Copyright (C) 2017 <NAME>
#
# This file is subject to the terms and conditions of the GNU Lesser
# General Public License v2.1. See the file LICENSE in the top level
# directory for more details.

import os
import sys
from testrunner import run


# on real hardware, this test application can take several minutes to
# complete (~4min on microbit)
HW_TIMEOUT = 300


def testfunc(child):
    board = os.environ['BOARD']
    # Increase timeout on "real" hardware
    timeout = HW_TIMEOUT if board is not 'native' else -1
    child.expect('OK \(\d+ tests\)', timeout=timeout)


if __name__ == "__main__":
    sys.exit(run(testfunc))
{'fraction_non_alphanumeric': 0.0997643362136685, 'fraction_numerical': 0.018067556952081697, 'mean_word_length': 3.9, 'pattern_counts': {'":': 2, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3932255', 'n_tokens_mistral': 406, 'n_tokens_neox': 386, 'n_words': 158}