aboutsummaryrefslogtreecommitdiffstats
path: root/testing
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2017-07-26 17:30:21 +0200
committerJakub Jirutka <jakub@jirutka.cz>2017-07-26 17:31:00 +0200
commitda228851ed762b6a7924b310bab03d0638f73129 (patch)
treeb3c63e589db9578858e596ab20d35929dccfcc03 /testing
parentf438501ceb2622c7bb870be2246c0c1e6d0f1ea6 (diff)
downloadaports-da228851ed762b6a7924b310bab03d0638f73129.tar.bz2
aports-da228851ed762b6a7924b310bab03d0638f73129.tar.xz
testing/tarantool: set up tests, but don't run them now
Diffstat (limited to 'testing')
-rw-r--r--testing/tarantool/APKBUILD20
-rw-r--r--testing/tarantool/tests-libressl-compat.patch35
-rw-r--r--testing/tarantool/tests-musl-compat.patch13
3 files changed, 65 insertions, 3 deletions
diff --git a/testing/tarantool/APKBUILD b/testing/tarantool/APKBUILD
index 104f22d22e..2f7c4e2058 100644
--- a/testing/tarantool/APKBUILD
+++ b/testing/tarantool/APKBUILD
@@ -12,18 +12,24 @@ license="BSD-2-Clause MIT Public-Domain"
pkgusers="$pkgname"
pkggroups="$pkgname"
install="$pkgname.pre-install"
+checkdepends="python2-dev py2-argparse py2-gevent py2-msgpack py2-six py2-yaml"
makedepends="cmake curl-dev luajit-dev libcoro-dev libressl-dev msgpuck-dev
perl python2 readline-dev yaml-dev zstd-dev"
subpackages="$pkgname-dev $pkgname-doc"
source="http://download.tarantool.org/tarantool/$_series/src/$pkgname-$pkgver.tar.gz
$pkgname.initd
- unbundle-dependencies.patch"
+ unbundle-dependencies.patch
+ tests-musl-compat.patch
+ tests-libressl-compat.patch"
builddir="$srcdir/$pkgname-$pkgver"
prepare() {
default_prepare
cd "$builddir"
+ # XXX: This test doesn't work, probably due to fakeroot.
+ rm test/xlog-py/misc.test.py
+
# msgpuck.h is in /usr/include, not /usr/include/msgpuck.
find . -name '*.c' -o -name '*.cc' \
| xargs -n 1 sed -Ei 's|#include\s*["<]msgpuck/msgpuck\.h[">]|#include <msgpuck.h>|'
@@ -63,7 +69,13 @@ build() {
}
check() {
- "$builddir"/src/tarantool --help > /dev/null
+ cd "$builddir"/test
+
+ ../src/tarantool --help > /dev/null
+
+ # TODO: Some tests are broken, fix it!
+ # --force means that it will not stop after first error.
+ #python2 test-run.py --force
}
package() {
@@ -74,4 +86,6 @@ package() {
sha512sums="c95a6900d9e9b9963bb038f28f3e47d0f8fd66159efef99b98b792cd08748481043d9a2a39c1c455094725e1ac213df731280587b93746ecb7bea2431deb7bf3 tarantool-1.7.4.335.tar.gz
fe463c4b6ab8708ea6ec17bb6a887677ae131a489d2ce299ce951790b7c134ff356bc1a4d4745878beec3600ec702944c2329a3f02645f8ab0a0eb24edb6215a tarantool.initd
-b48eefdf71e20db22c4366e4573441a0d4e5f6e727fc23b2b41534e8d5cc7dc9cc08baf2bf1cf1950c7b0e211920abb4254c2d1e972ec884db25800820824f2c unbundle-dependencies.patch"
+b48eefdf71e20db22c4366e4573441a0d4e5f6e727fc23b2b41534e8d5cc7dc9cc08baf2bf1cf1950c7b0e211920abb4254c2d1e972ec884db25800820824f2c unbundle-dependencies.patch
+f6fec037780f830eb353b184d190b5dc8b481164c9cd06991f921d70be8cababb5dba43e5af96abe6fb87fda44c5573d706f7b032bc996d33debb7811b84addb tests-musl-compat.patch
+146744f2e7265de2644c03d7beb6ce1657b63a99db9c4527cb603c915082dc1184a90e92ba39bfb946f2f8f7a2b866cc8343c7e865d4245fe704447a59cc4846 tests-libressl-compat.patch"
diff --git a/testing/tarantool/tests-libressl-compat.patch b/testing/tarantool/tests-libressl-compat.patch
new file mode 100644
index 0000000000..7816bf406a
--- /dev/null
+++ b/testing/tarantool/tests-libressl-compat.patch
@@ -0,0 +1,35 @@
+Fix crypto/digest tests to be compatible with LibreSSL.
+
+--- a/test/app/crypto.result
++++ b/test/app/crypto.result
+@@ -111,13 +111,13 @@
+ ...
+ ciph.decrypt(enc, bad_pass, iv)
+ ---
+-- error: 'builtin/crypto.lua:<line>"]: Can''t finalize cipher:error:06065064:digital envelope
+- routines:EVP_DecryptFinal_ex:bad decrypt'
++- error: 'builtin/crypto.lua:<line>"]: Can''t finalize cipher:error:06FFF064:digital envelope
++ routines:CRYPTO_internal:bad decrypt'
+ ...
+ ciph.decrypt(enc, pass, bad_iv)
+ ---
+-- error: 'builtin/crypto.lua:<line>"]: Can''t finalize cipher:error:06065064:digital envelope
+- routines:EVP_DecryptFinal_ex:bad decrypt'
++- error: 'builtin/crypto.lua:<line>"]: Can''t finalize cipher:error:06FFF064:digital envelope
++ routines:CRYPTO_internal:bad decrypt'
+ ...
+ test_run:cmd("clear filter")
+ ---
+--- a/test/app/digest.result
++++ b/test/app/digest.result
+@@ -445,8 +445,8 @@
+ ...
+ digest.aes256cbc.decrypt(digest.aes256cbc.encrypt('test123', 'passpasspasspasspasspasspasspass', 'iv12tras8712cvbh'), 'nosspasspasspasspasspasspasspass', 'iv12tras8712cvbh')
+ ---
+-- error: 'builtin/crypto.lua:<line>"]: Can''t finalize cipher:error:06065064:digital envelope
+- routines:EVP_DecryptFinal_ex:bad decrypt'
++- error: 'builtin/crypto.lua:<line>"]: Can''t finalize cipher:error:06FFF064:digital envelope
++ routines:CRYPTO_internal:bad decrypt'
+ ...
+ digest = nil
+ ---
diff --git a/testing/tarantool/tests-musl-compat.patch b/testing/tarantool/tests-musl-compat.patch
new file mode 100644
index 0000000000..f39fb8735b
--- /dev/null
+++ b/testing/tarantool/tests-musl-compat.patch
@@ -0,0 +1,13 @@
+Fix fiber test to be compatible with musl libc.
+
+--- a/test/unit/fiber.result
++++ b/test/unit/fiber.result
+@@ -1,6 +1,6 @@
+-#gh-1238: log uncaught errors
+-SystemError Failed to allocate 42 bytes in allocator for exception: Cannot allocate memory
+ *** fiber_name_test ***
++#gh-1238: log uncaught errors
++SystemError Failed to allocate 42 bytes in allocator for exception: Out of memory
+ # name of a new fiber: main.
+
+ # set new fiber name: Horace.