summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xtests/t0400-grep.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/t0400-grep.sh b/tests/t0400-grep.sh
new file mode 100755
index 0000000..0c55cf8
--- /dev/null
+++ b/tests/t0400-grep.sh
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+test_description='Grep check'
+. ./setup.sh
+
+test_expect_success 'Make sure grep prints normal lines' '
+ pass init $KEY1 &&
+ pass insert -e blah1 <<<"hello" &&
+ pass insert -e blah2 <<<"my name is" &&
+ pass insert -e folder/blah3 <<<"I hate computers" &&
+ pass insert -e blah4 <<<"me too!" &&
+ pass insert -e folder/where/blah5 <<<"They are hell" &&
+ results="$(pass grep hell)" &&
+ [[ $(wc -l <<<"$results") -eq 4 ]] &&
+ grep -q blah5 <<<"$results" &&
+ grep -q blah1 <<<"$results" &&
+ grep -q "They are" <<<"$results"
+'
+
+test_done
>3-12/+21 2021-02-15Issue #46: Improvements; add testsRené 'Necoro' Neumann2-1/+48 2021-02-15Bump github.com/google/uuid from 1.1.4 to 1.2.0dependabot[bot]2-3/+3 2021-02-15Issue #46: Make the resulting email body not to include single \r or \n. This...René 'Necoro' Neumann2-2/+66 2021-01-20Bump github.com/PuerkitoBio/goquery from 1.6.0 to 1.6.1dependabot[bot]2-3/+3 2021-01-09Bump github.com/google/uuid from 1.1.2 to 1.1.4dependabot[bot]2-3/+3 2021-01-09Bump github.com/emersion/go-message from 0.14.0 to 0.14.1 (#42)dependabot[bot]2-3/+3 2020-11-28Bump github.com/emersion/go-message from 0.13.0 to 0.14.0 (#38)dependabot[bot]2-3/+9 2020-11-28Bump github.com/google/go-cmp from 0.5.2 to 0.5.4 (#37)dependabot[bot]2-3/+3 2020-11-23Fix release.ymlv0.5.2René 'Necoro' Neumann1-3/+10 2020-11-23Prepare v0.5.2René 'Necoro' Neumann3-3/+8 2020-11-20Bump github.com/gabriel-vasile/mimetype from 1.1.1 to 1.1.2dependabot[bot]2-3/+3 2020-11-04Clean dependabot.ymlRené 'Necoro' Neumann1-4/+0