File: T660-bad-date.sh

package info (click to toggle)
notmuch 0.39-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 7,104 kB
  • sloc: sh: 21,888; ansic: 14,897; lisp: 9,061; cpp: 7,990; python: 6,221; perl: 391; makefile: 231; javascript: 34; ruby: 13
file content (14 lines) | stat: -rwxr-xr-x 396 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/usr/bin/env bash
test_description="parsing of bad dates"
. $(dirname "$0")/test-lib.sh || exit 1

add_message [date]='"()"'

test_begin_subtest 'Bad dates translate to a date after the Unix epoch'
cat <<EOF >EXPECTED
thread:0000000000000001   1970-01-01 [1/1] Notmuch Test Suite; Test message #1 (inbox unread)
EOF
notmuch search '*' > OUTPUT
test_expect_equal_file EXPECTED OUTPUT

test_done