aboutsummaryrefslogtreecommitdiff
path: root/lib/mlibc/tests/glibc/error.py
blob: 38339741ba2973089f6cc9b5229f9c57f78cc4bd (plain)
1
2
3
4
5
6
7
8
9
10
11
import subprocess
import sys
import os
from pyexpect import expect

wrapper = os.getenv("MESON_EXE_WRAPPER")
wrapper = [x for x in (wrapper,) if x]

output = subprocess.check_output(wrapper + [sys.argv[1]], stderr=subprocess.STDOUT)

expect(bytes(sys.argv[1], 'utf-8') + b': test: error: Invalid argument (EINVAL)\n').to_equal(output)