summaryrefslogtreecommitdiffstatshomepage
path: root/tests/basics/memoryerror.py
blob: e9aa97d85847ee3c470e712ff319fc1619dd36d1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
# this test for MemoryError can be difficult to reproduce
# on different machine configurations (notably Travis CI)
# so we disable it
# TODO is there a way of testing that we are on Travis CI?
if False:
    l = list(range(10000))
    try:
        100000000 * l
    except MemoryError:
        print('MemoryError')
    print(len(l), l[0], l[-1])