aboutsummaryrefslogtreecommitdiff
path: root/support/testing/tests/package/test_ipython.py
blob: 3b291d9583e92072a66411434d524b0e1d95525e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
from tests.package.test_python import TestPythonBase
#
# The following pythong tests are not being used here:
#
# - version_test: IPython does not support --version option
#
# - zlib_test: IPython does not return a non-zero code the way CPython
#              does, so this test ends up being a false-negative


class TestIPythonPy2(TestPythonBase):
    config = TestPythonBase.config + \
        """
        BR2_PACKAGE_PYTHON=y
        BR2_PACKAGE_PYTHON_IPYTHON=y
        """
    interpreter = "ipython"

    def test_run(self):
        self.login()
        self.math_floor_test(40)
        self.libc_time_test(40)


class TestIPythonPy3(TestPythonBase):
    config = TestPythonBase.config + \
        """
        BR2_PACKAGE_PYTHON3=y
        BR2_PACKAGE_PYTHON_IPYTHON=y
        """
    interpreter = "ipython"

    def test_run(self):
        self.login()
        self.math_floor_test(40)
        self.libc_time_test(40)