summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/core/tests/cases/timeout.py
blob: 5dfecc7b7c3b8910839ab1a9eef57ca99c54fd51 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#
# Copyright (C) 2016 Intel Corporation
#
# SPDX-License-Identifier: MIT
#

from time import sleep

from oeqa.core.case import OETestCase
from oeqa.core.decorator.oetimeout import OETimeout

class TimeoutTest(OETestCase):

    @OETimeout(1)
    def testTimeoutPass(self):
        self.assertTrue(True, msg='How is this possible?')

    @OETimeout(1)
    def testTimeoutFail(self):
        sleep(2)
        self.assertTrue(True, msg='How is this possible?')