Commit 9a5cfb73 authored by Kirill Smelkov's avatar Kirill Smelkov

zodbtools: Add way to run tests

Following approach used for pygolang in the previous patch lets add
testing support for zodbtools:

- Add zodbtools/buildout-dev.cfg that overrides [zodbtools] to use the
  software from git checkout.

- Add zodbtools/test<X>.cfg that is software-release to create a test
  instance to be run under testnode. To help itself on this task this
  software release uses just-added stack/nxdtest.cfg and
  [python-interpreter] from pygolang, so the code in zodbtools is
  minimal.

Zodbtools can be tested against both ZODB4 and ZODB5 because we still
use ZODB4 as our primary ZODB version, but it is no longer supported by
upstream which considers only ZODB5 as current.
parent 662b1a0b
# SlapOS component for zodbtools development.
[buildout]
extends =
buildout.cfg
../git/buildout.cfg
# override zodbtools to install it from latest git version
[zodbtools]
recipe = zc.recipe.egg:develop
setup = ${zodbtools-repository:location}
[zodbtools-repository]
recipe = slapos.recipe.build:gitclone
repository = https://lab.nexedi.com/nexedi/zodbtools.git
branch = master
location = ${buildout:parts-directory}/zodbtools-dev
git-executable = ${git:location}/bin/git
# unpin zodbtools from versions, so that buildout does not fallback to
# installing non-dev egg if dev one has changed its version.
[versions]
zodbtools =
# SlapOS software release to test zodbtools on Nexedi testing infrastructure.
# Common parts.
[buildout]
extends =
# test*.cfg first extend from neoppod/software<ZODB-flabour>.cfg to use
# appropriate ZODB and versions of other components.
../../stack/nxdtest.cfg
../pytest/buildout.cfg
buildout-dev.cfg
parts =
zodbtools
# for instance
zodbtools-python
slapos-cookbook
instance.cfg
# bin/python is preinstalled with sys.path to zodbtools & friends.
[zodbtools-python]
<= python-interpreter
eggs = zodbtools[test]
# env.sh for zodbtools's python to be on $PATH.
[zodbtools-env.sh]
recipe = slapos.recipe.template:jinja2
rendered = ${buildout:directory}/${:_buildout_section_name_}
template = inline:
export PS1="(zodbtools-env) $PS1"
export PATH=${buildout:bin-directory}:$PATH
# instance to run nxdtest.
[instance.cfg]
<= jinja2-template
template = inline:
[buildout]
extends = ${nxdtest-instance.cfg:rendered}
[runTestSuite]
env.sh = ${zodbtools-env.sh:rendered}
workdir = ${zodbtools-repository:location}
[versions]
freezegun = 1.0.0
# SlapOS software release to test zodbtools/ZODB5 on Nexedi testing infrastructure.
[buildout]
extends =
../../software/neoppod/software-zodb5.cfg
test-common.cfg
# SlapOS software release to test zodbtools on Nexedi testing infrastructure.
[buildout]
extends =
../../software/neoppod/software.cfg
test-common.cfg
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