Files
chatmail-core/run-integration-tests.sh
Floris Bruynooghe 6c9e16d31a Introduce a BlobObject type for blobs
This creates a specific type for blobs, with well defined conversions
at the borders.  It also introduces a strong type for the Param::File
value since that param is often used used by the public API to set
filenames using absolute paths, but then core changes the param to a
blob before it gets to the database.

This eliminates a few more functions with very mallable C-like
arguments behaviour which combine a number of operations in one.
Because blob filenames are stored so often in arbitrary strings this
does add more code when receiving those, until the storage is fixed.

File name sanitisation is now deletated to the sanitize-filename crate
which should do a slightly better job at this.
2019-10-22 18:54:09 +02:00

33 lines
691 B
Bash
Executable File

#!/bin/bash
# Small helper to easily run integration tests locally for development
# purposes. Any arguments are passed straight to tox. E.g. to run
# only one environment run with:
#
# ./run-integration-tests.sh -e py35
#
# To also run with `pytest -x` use:
#
# ./run-integration-tests.sh -e py35 -- -x
export DCC_RS_DEV=$(pwd)
export DCC_RS_TARGET=${DCC_RS_TARGET:-release}
if [ $DCC_RS_TARGET = 'release' ]; then
cargo build -p deltachat_ffi --release
else
cargo build -p deltachat_ffi
fi
if [ $? != 0 ]; then
exit $?
fi
pushd python
if [ -e "./liveconfig" -a -z "$DCC_PY_LIVECONFIG" ]; then
export DCC_PY_LIVECONFIG=liveconfig
fi
tox "$@"
ret=$?
popd
exit $ret