From: David Bremner <david@tethera.net>
To: notmuch@notmuchmail.org
Subject: [PATCH 1/4] test: make python tests compatible with python3
Date: Sat, 23 May 2015 22:28:44 +0200 [thread overview]
Message-ID: <1432412927-8373-2-git-send-email-david@tethera.net> (raw)
In-Reply-To: <1432412927-8373-1-git-send-email-david@tethera.net>
Making the test suite actually run them with python3 is left for
future work.
---
test/T390-python.sh | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/test/T390-python.sh b/test/T390-python.sh
index 3f03a2e..26d0b97 100755
--- a/test/T390-python.sh
+++ b/test/T390-python.sh
@@ -11,7 +11,7 @@ db = notmuch.Database(mode=notmuch.Database.MODE.READ_ONLY)
q_new = notmuch.Query(db, 'tag:inbox')
q_new.set_sort(notmuch.Query.SORT.OLDEST_FIRST)
for t in q_new.search_threads():
- print t.get_thread_id()
+ print (t.get_thread_id())
EOF
notmuch search --sort=oldest-first --output=threads tag:inbox | sed s/^thread:// > EXPECTED
test_expect_equal_file OUTPUT EXPECTED
@@ -23,7 +23,7 @@ db = notmuch.Database(mode=notmuch.Database.MODE.READ_ONLY)
q_new = notmuch.Query(db, 'tag:inbox')
q_new.set_sort(notmuch.Query.SORT.OLDEST_FIRST)
for m in q_new.search_messages():
- print m.get_message_id()
+ print (m.get_message_id())
EOF
notmuch search --sort=oldest-first --output=messages tag:inbox | sed s/^id:// > EXPECTED
test_expect_equal_file OUTPUT EXPECTED
@@ -32,7 +32,7 @@ test_begin_subtest "get non-existent file"
test_python <<EOF
import notmuch
db = notmuch.Database(mode=notmuch.Database.MODE.READ_ONLY)
-print db.find_message_by_filename("i-dont-exist")
+print (db.find_message_by_filename("i-dont-exist"))
EOF
test_expect_equal "$(cat OUTPUT)" "None"
--
2.1.4
next prev parent reply other threads:[~2015-05-23 20:31 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-23 20:28 Support running test suite using python3 David Bremner
2015-05-23 20:28 ` David Bremner [this message]
2015-05-23 20:28 ` [PATCH 2/4] configure: add ability to force python version via environment David Bremner
2015-05-23 20:28 ` [PATCH 3/4] test: use the python interpreter in sh.configure David Bremner
2015-06-08 14:50 ` David Bremner
2015-08-02 6:40 ` [PATCH] test: use the python interpreter in sh.config David Bremner
2015-08-02 8:31 ` Tomi Ollila
2015-08-04 14:35 ` David Bremner
2015-05-23 20:28 ` [PATCH 4/4] test: redirect man output to /dev/null David Bremner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1432412927-8373-2-git-send-email-david@tethera.net \
--to=david@tethera.net \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).