]> the.earth.li Git - onak.git/blob - t/all-045-index-text-v5.t
0cf8bcc46ae83fcc18afe3d8c94347fde4ad2029
[onak.git] / t / all-045-index-text-v5.t
1 #!/bin/sh
2 # Check we can index a key by some uid text
3
4 set -e
5
6 # Backends should really support this, but the file one is as simple as
7 # possible, so doesn't. Skip the test for it.
8 if [ "$2" = "file" ]; then
9         exit 0
10 fi
11
12 cd ${WORKDIR}
13 ${BUILDDIR}/onak -b -c $1 add < ${TESTSDIR}/../keys/v5-test.key
14 if ! ${BUILDDIR}/onak -c $1 index emma 2> /dev/null | \
15         grep -q -- \
16         'pub    255E/87246402 2019/03/20 emma.goldman@example.net'; then
17         echo "* Did not correctly retrieve key by text"
18         exit 1
19 fi
20
21 exit 0