Commit 0d67ef12 authored by Marius Wachtler's avatar Marius Wachtler

avro test: looks like one test fails because a domain is down

cpython encounters the same error
I took the opportunity to switch to py.test from nose
now that we support it and this is how one should test this package.
parent a0e63008
...@@ -5,10 +5,10 @@ from test_helper import create_virtenv, run_test ...@@ -5,10 +5,10 @@ from test_helper import create_virtenv, run_test
ENV_NAME = "avro_test_env_" + os.path.basename(sys.executable) ENV_NAME = "avro_test_env_" + os.path.basename(sys.executable)
PYTHON_EXE = os.path.abspath(os.path.join(ENV_NAME, "bin", "python")) PYTHON_EXE = os.path.abspath(os.path.join(ENV_NAME, "bin", "python"))
NOSETESTS_EXE = os.path.abspath(os.path.join(ENV_NAME, "bin", "nosetests")) PYTEST_EXE = os.path.abspath(os.path.join(ENV_NAME, "bin", "py.test"))
AVRO_DIR = os.path.abspath(os.path.join(ENV_NAME, "avro-1.7.7")) AVRO_DIR = os.path.abspath(os.path.join(ENV_NAME, "avro-1.7.7"))
packages = ["nose==1.3.7", "avro==1.7.7"] packages = ["pytest==2.8.7", "py==1.4.29", "avro==1.7.7"]
create_virtenv(ENV_NAME, packages, force_create = True) create_virtenv(ENV_NAME, packages, force_create = True)
url = "https://pypi.python.org/packages/source/a/avro/avro-1.7.7.tar.gz" url = "https://pypi.python.org/packages/source/a/avro/avro-1.7.7.tar.gz"
...@@ -18,7 +18,6 @@ subprocess.check_call(["tar", "-zxf", "avro-1.7.7.tar.gz"], cwd=ENV_NAME) ...@@ -18,7 +18,6 @@ subprocess.check_call(["tar", "-zxf", "avro-1.7.7.tar.gz"], cwd=ENV_NAME)
env = os.environ env = os.environ
env["PYTHONPATH"] = os.path.abspath(os.path.join(ENV_NAME, "lib/python2.7/site-packages")) env["PYTHONPATH"] = os.path.abspath(os.path.join(ENV_NAME, "lib/python2.7/site-packages"))
# this tests also fail when run in cpython with nose. # cpython has the same number of failures
# pytest makes two of this work but we can't currently run pytest... expected = [{'failed': 2, 'passed': 47}]
expected = [{'ran': 51, 'errors': 3}] run_test([PYTEST_EXE], env=env, cwd=AVRO_DIR, expected=expected)
run_test([NOSETESTS_EXE], env=env, cwd=AVRO_DIR, expected=expected)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment