File tree Expand file tree Collapse file tree 10 files changed +57
-20
lines changed Expand file tree Collapse file tree 10 files changed +57
-20
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,16 @@ markers =
1818 requests: mark a test as test of the requests library instrumentation
1919 boto3: mark a test as test of the boto3 library instrumentation
2020 elasticsearch: mark a test as elasticsearch test
21+ gevent
22+ celery
23+ opentracing
24+ zerorpc
25+ cassandra
26+ psycopg2
27+ mongodb
28+ memcached
29+ redis
30+ psutil
2131
2232[isort]
2333line_length =120
Original file line number Diff line number Diff line change 4040from elasticapm .conf .constants import TRANSACTION
4141from elasticapm .instrumentation .packages .dbapi2 import extract_signature
4242
43- pytestmark = pytest .mark .cassandra
43+ pytestmark = [pytest .mark .cassandra ]
44+
45+ if "CASSANDRA_HOST" not in os .environ :
46+ pytestmark .append (pytest .mark .skip ("Skipping cassandra tests, no CASSANDRA_HOST environment variable set" ))
4447
4548
4649@pytest .fixture ()
Original file line number Diff line number Diff line change 3939
4040from elasticapm .conf .constants import TRANSACTION
4141
42+ pytestmark = [pytest .mark .elasticsearch ]
43+
4244if "ES_URL" not in os .environ :
43- pytestmark = pytest .mark .skip ("Skipping elasticsearch test, no ES_URL environment variable" )
44- else :
45- pytestmark = pytest .mark .elasticsearch
45+ pytestmark .append (pytest .mark .skip ("Skipping elasticsearch test, no ES_URL environment variable" ))
46+
4647
4748document_type = "_doc" if ES_VERSION [0 ] >= 6 else "doc"
4849
Original file line number Diff line number Diff line change 3737
3838pylibmc = pytest .importorskip ("pylibmc" )
3939
40- pytestmark = pytest .mark .pylibmc
40+ pytestmark = [pytest .mark .pylibmc ]
41+
42+ if "MEMCACHED_HOST" not in os .environ :
43+ pytestmark .append (pytest .mark .skip ("Skipping pylibmc tests, no MEMCACHED_HOST environment variable set" ))
4144
4245
4346@pytest .mark .integrationtest
Original file line number Diff line number Diff line change 3838pymongo = pytest .importorskip ("pymongo" )
3939
4040
41- pytestmark = pytest .mark .mongodb
41+ pytestmark = [pytest .mark .mongodb ]
42+
43+ if "MONGODB_HOST" not in os .environ :
44+ pytestmark .append (pytest .mark .skip ("Skipping mongodb tests, no MONGODB_HOST environment variable set" ))
4245
4346
4447@pytest .fixture ()
Original file line number Diff line number Diff line change 3636
3737pymssql = pytest .importorskip ("pymssql" )
3838
39- pytestmark = pytest .mark .pymssql
39+ pytestmark = [pytest .mark .pymssql ]
40+
41+
42+ if "MSSQL_HOST" not in os .environ :
43+ pytestmark .append (pytest .mark .skip ("Skipping MS-SQL tests, no MSSQL_HOST environment variable set" ))
4044
4145
4246@pytest .yield_fixture (scope = "function" )
Original file line number Diff line number Diff line change 3636
3737pyodbc = pytest .importorskip ("pyodbc" )
3838
39- pytestmark = pytest .mark .pyodbc
39+ pytestmark = [pytest .mark .pyodbc ]
40+
41+
42+ if "POSTGRES_DB" not in os .environ :
43+ pytestmark .append (pytest .mark .skip ("Skipping pyodbc tests, no POSTGRES_DB environment variable set" ))
4044
4145
4246@pytest .yield_fixture (scope = "function" )
Original file line number Diff line number Diff line change 3838memcache = pytest .importorskip ("memcache" ) # isort:skip
3939
4040
41- pytestmark = pytest .mark .memcached
41+ pytestmark = [pytest .mark .memcached ]
42+
43+
44+ if "MEMCACHED_HOST" not in os .environ :
45+ pytestmark .append (pytest .mark .skip ("Skipping memchached tests, no MEMCACHED_HOST environment variable set" ))
4246
4347
4448@pytest .mark .integrationtest
Original file line number Diff line number Diff line change 4141from elasticapm .conf .constants import TRANSACTION
4242from elasticapm .traces import capture_span
4343
44+ pytestmark = [pytest .mark .redis ]
45+
4446if "REDIS_HOST" not in os .environ :
45- pytestmark = pytest .mark .skip ("Skipping redis tests, no REDIS_HOST environment variable set" )
46- else :
47- pytestmark = pytest .mark .redis
47+ pytestmark .append (pytest .mark .skip ("Skipping redis tests, no REDIS_HOST environment variable set" ))
4848
4949
5050@pytest .fixture ()
Original file line number Diff line number Diff line change 1- pytest==3.10.1
2- py==1.7 .0
1+ pytest==4.6.5
2+ py==1.8 .0
33more-itertools==4.1.0
4- pluggy==0.8 .0
5- pytest-django==3.4.4
4+ pluggy==0.13 .0
5+ pytest-django==3.5.1
66atomicwrites==1.1.5
7- coverage==4.5.2
8- pytest-cov==2.6.0
7+ coverage==4.5.4
8+ pytest-cov==2.7.1
99pytest-localserver==0.5.0
10- pytest-mock==1.10.0
11- pytest-benchmark==3.1.1
10+ pytest-mock==1.10.4
11+ pytest-benchmark==3.2.2
1212jsonschema==2.6.0
13+ configparser==4.0.2
14+ contextlib2==0.6.0
15+ importlib-metadata==0.23
16+ packaging==19.2
17+
1318
1419docutils==0.14
1520pathlib==1.0.1
You can’t perform that action at this time.
0 commit comments