diff --git a/tests/smoke/smoke.fmf b/tests/smoke/smoke.fmf new file mode 100644 index 0000000..69c01da --- /dev/null +++ b/tests/smoke/smoke.fmf @@ -0,0 +1,5 @@ +test: python3 test.py +framework: shell +require: +- python3 +- python3-urllib3 diff --git a/tests/smoke/test.py b/tests/smoke/test.py new file mode 100644 index 0000000..d622ddd --- /dev/null +++ b/tests/smoke/test.py @@ -0,0 +1,9 @@ +import urllib3 + +http = urllib3.PoolManager() +r = http.request('GET', 'http://example.com/') +print('status = {0}'.format(r.status)) +print("headers['server'] = {0}".format(r.headers['server'])) +print(r.data) +if r.status != 200 or not r.data: + raise SystemExit(1)