Updated the buildout configuration to just run relstorage tests and
to select which databases to use at build time.
This commit is contained in:
parent
01ae65b713
commit
3a49a6b23e
|
@ -0,0 +1,18 @@
|
||||||
|
========================================
|
||||||
|
Building for running tests with buildout
|
||||||
|
========================================
|
||||||
|
|
||||||
|
Run the buildout as usual, but to include database support specify a
|
||||||
|
db option, with one or more database names sperated by commas. For
|
||||||
|
example, to build for postgres, mysql and oracle::
|
||||||
|
|
||||||
|
bin/buildout db=postgresql,mysql,oracle
|
||||||
|
|
||||||
|
Or just postgres:
|
||||||
|
|
||||||
|
bin/buildout db=postgresql
|
||||||
|
|
||||||
|
Before running tests, you'll need to run database setup scripts in the
|
||||||
|
``.travis`` subdirectory.
|
||||||
|
|
||||||
|
Then run tests with ``bin/test``.
|
|
@ -11,6 +11,9 @@
|
||||||
psycopg2cffi respectively. PyPy can be substantially faster than
|
psycopg2cffi respectively. PyPy can be substantially faster than
|
||||||
CPython in some scenarios; see `PR 23`_.
|
CPython in some scenarios; see `PR 23`_.
|
||||||
|
|
||||||
|
- Updated the buildout configuration to just run relstorage tests and
|
||||||
|
to select which databases to use at build time.
|
||||||
|
|
||||||
.. _`PR 23`: https://github.com/zodb/relstorage/pull/23/
|
.. _`PR 23`: https://github.com/zodb/relstorage/pull/23/
|
||||||
|
|
||||||
1.6.0b3 (2014-12-08)
|
1.6.0b3 (2014-12-08)
|
||||||
|
|
14
buildout.cfg
14
buildout.cfg
|
@ -1,17 +1,17 @@
|
||||||
[buildout]
|
[buildout]
|
||||||
develop = .
|
develop = .
|
||||||
base-parts = test python omelette coverage-test coverage-report
|
base-parts = test py python omelette coverage-test coverage-report
|
||||||
parts = ${buildout:base-parts}
|
parts = ${buildout:base-parts}
|
||||||
eggs = relstorage
|
eggs = relstorage
|
||||||
psycopg2
|
db =
|
||||||
MySQL-python
|
|
||||||
ZODB3 [test]
|
|
||||||
zope.testrunner
|
|
||||||
mock
|
|
||||||
|
|
||||||
[test]
|
[test]
|
||||||
recipe = zc.recipe.testrunner
|
recipe = zc.recipe.testrunner
|
||||||
eggs = ${buildout:eggs}
|
eggs = relstorage [test, ${buildout:db}]
|
||||||
|
|
||||||
|
[py]
|
||||||
|
recipe = zc.recipe.egg
|
||||||
|
eggs = ${test:eggs}
|
||||||
|
|
||||||
[python]
|
[python]
|
||||||
recipe = zc.recipe.egg
|
recipe = zc.recipe.egg
|
||||||
|
|
8
setup.py
8
setup.py
|
@ -45,6 +45,8 @@ def read_file(*path):
|
||||||
result = f.read()
|
result = f.read()
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
tests_require = ['mock', 'zope.testing', 'ZODB [test]']
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="RelStorage",
|
name="RelStorage",
|
||||||
version=VERSION,
|
version=VERSION,
|
||||||
|
@ -80,10 +82,7 @@ setup(
|
||||||
'zope.interface',
|
'zope.interface',
|
||||||
'zc.lockfile',
|
'zc.lockfile',
|
||||||
],
|
],
|
||||||
tests_require=[
|
tests_require = tests_require,
|
||||||
'mock',
|
|
||||||
'zope.testing',
|
|
||||||
],
|
|
||||||
extras_require={
|
extras_require={
|
||||||
'mysql:platform_python_implementation=="CPython"': [
|
'mysql:platform_python_implementation=="CPython"': [
|
||||||
'MySQL-python>=1.2.2',
|
'MySQL-python>=1.2.2',
|
||||||
|
@ -100,6 +99,7 @@ setup(
|
||||||
'oracle': [
|
'oracle': [
|
||||||
'cx_Oracle>=4.3.1'
|
'cx_Oracle>=4.3.1'
|
||||||
],
|
],
|
||||||
|
'test': tests_require,
|
||||||
},
|
},
|
||||||
entry_points = {
|
entry_points = {
|
||||||
'console_scripts': [
|
'console_scripts': [
|
||||||
|
|
Loading…
Reference in New Issue