[PATCH 3/9] test: ruby: simplify MAIL_DIR check

Subject: [PATCH 3/9] test: ruby: simplify MAIL_DIR check

Date: Sat, 1 May 2021 06:59:17 -0500

To: notmuch@notmuchmail.org

Cc: Daniel Kahn Gillmor, Ludovic LANGE, Tomi Ollila, Stefano Zacchiroli

From: Felipe Contreras


Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
---
 test/T395-ruby.sh | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/test/T395-ruby.sh b/test/T395-ruby.sh
index 1d27e191..94fab106 100755
--- a/test/T395-ruby.sh
+++ b/test/T395-ruby.sh
@@ -12,10 +12,7 @@ test_ruby() {
     (
 	cat <<-\EOF
 	require 'notmuch'
-	$maildir = ENV['MAIL_DIR']
-	if not $maildir then
-	  abort('environment variable MAIL_DIR must be set')
-	end
+	$maildir = ENV['MAIL_DIR'] || abort('MAIL_DIR not set')
 	@db = Notmuch::Database.new($maildir)
 	EOF
 	cat
-- 
2.31.0
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: