From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 5nr6KDcNq2AwRQAAgWs5BA (envelope-from ) for ; Mon, 24 May 2021 04:19:35 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id G2EfJDcNq2BBKwAAB5/wlQ (envelope-from ) for ; Mon, 24 May 2021 02:19:35 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [IPv6:2607:5300:201:3100::1657]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id E80371451D for ; Mon, 24 May 2021 04:19:34 +0200 (CEST) Received: from nmbug.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 539D72AB36; Sun, 23 May 2021 22:19:28 -0400 (EDT) Received: from mail-oi1-x236.google.com (mail-oi1-x236.google.com [IPv6:2607:f8b0:4864:20::236]) by mail.notmuchmail.org (Postfix) with ESMTPS id B88942AB1A for ; Sun, 23 May 2021 22:19:16 -0400 (EDT) Received: by mail-oi1-x236.google.com with SMTP id h9so25822511oih.4 for ; Sun, 23 May 2021 19:19:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=5XWwSdOmXTfO35FiIlkqcp067W/sxfW3sY+rPHTPFgM=; b=aGE0NOkFw4KjFNpxbwRGAnE6GdjDdKH6kz6rj0k75rGhJjpvBrVv7zS8AzD1Rj1JDc aWV5v6fZ5jwe5Db+NxyLDItn0+MNw49cBvGJ2IPcQiL7ZUsTGkgA4tUJscmpomHpXe3m lAynr9TY2MsHDShphl/ByPpsLOKdOGg/yucd9BqF95mweOUdrg1klxGsOUwHEHCZx5wo wvoAoX4fg3FTyn9OpWflbRaa6dwXLy09hg5UGKr48iKd5RK1lAWuxBgJUuJP54JesUWx DcAWmDMSofJZ2kgQ4PLjYL0wRY2AFtZQ7EjZDRs8jVrQOGao54Phc0jqgjH//vFF1tQR aqNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=5XWwSdOmXTfO35FiIlkqcp067W/sxfW3sY+rPHTPFgM=; b=lsy6xYiZCI3L47kDGM/QxhqR+1aq03hQuzTqk5YFLQ0yN39ooBJs6pPsN3WR4TE7Er Ky4ZOBBPib+QfYy7m4LWr2WrroKC4RBojd5Xkp3iIgnByijYEW4sVyyJMdW8ffnNsRfI Q+sNiZJQqk8npmwMxkmZ/qTQ8mdNKrQC0z12wYH3VowOG6mvdlZAVrAzAXro2gS2OVEh bxG4lxpEgM9Y5hENGdqx8BPe3Zih7824XPUjTVUwWlQifdtdQMf/e0hR3YZq4HBPM0/J kSMO2zVwHpH7pJJAndd6o1G123ggenG0tVQXnWaZOPStjdCN5qjet+z0HgDZYsV0D4yN qLtw== X-Gm-Message-State: AOAM530PUZzHcl1PFbmqLqsO/edadWDAC19BqLaWNTc8fwNzZhtGLb6F 0lIK+lBenkudWfsYFlAYJEN7bGTwXIP3jQ== X-Google-Smtp-Source: ABdhPJxcCvCpBjSLEhmVBex2OpnlQCWDE7r7xetV993lG5y8nMRfMuLQAcqGKss1nf8xcB1XfBPE3Q== X-Received: by 2002:a05:6808:13ca:: with SMTP id d10mr9392282oiw.24.1621822755850; Sun, 23 May 2021 19:19:15 -0700 (PDT) Received: from localhost (fixed-187-190-78-172.totalplay.net. [187.190.78.172]) by smtp.gmail.com with ESMTPSA id 77sm2777274otc.54.2021.05.23.19.19.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 23 May 2021 19:19:15 -0700 (PDT) From: Felipe Contreras To: notmuch@notmuchmail.org Subject: [PATCH v2 2/2] test: ruby: simplify basic tests Date: Sun, 23 May 2021 21:19:10 -0500 Message-Id: <20210524021910.92145-3-felipe.contreras@gmail.com> X-Mailer: git-send-email 2.32.0.rc0 In-Reply-To: <20210524021910.92145-1-felipe.contreras@gmail.com> References: <20210524021910.92145-1-felipe.contreras@gmail.com> MIME-Version: 1.0 Message-ID-Hash: KAZ5TO4BZ72MPV5XTNMBNVJEUSIDKZWN X-Message-ID-Hash: KAZ5TO4BZ72MPV5XTNMBNVJEUSIDKZWN X-MailFrom: felipe.contreras@gmail.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header CC: Ludovic LANGE , Stefano Zacchiroli X-Mailman-Version: 3.2.1 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1621822775; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=BV1NntvPxmY+4HkdiehODYYE+6EPwqTAXDOj1FEIqMs=; b=mmjrKKgKjo4wlpnoG9VnpJ59fg0RbMa2kNa1oqOL6aoe7JPBnbZF2bzUnYP31B/RnpQDDc Zh2VlM/OL6nUggKM+rmuGyc3B1/a9Qw6FyaCQbgtXfHSEmmXOxXlPJKBbi3vFAkTuzmJiA VSkMzGum0LIvj1/EUJY/+WU34JRzRSjwdTZAEbMxcNual5g0h0dUhp7F9AJ7+5FCfv8kwi kD57veY2JGtBfX0JFZk0XhEJqq8vKgWIztpf8wZn0ykYGn4L2qK3LbPro1lgaM3/Lg44iq hv5HiSjWmtBx0TYNQC5HZ68ZsFYM5gSPP4Gor4cMjCt9RIlKb2FZYK+Z1KL9Mg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1621822775; a=rsa-sha256; cv=none; b=S1Mu9EflJQKZjmEQePDaTFFZS/ciSeLd2xGEuwzKpjmwgOsC5Wi4EKeHrBoJcMCN3kTkDA BRd6U/qRz/Thdfxp3VYujGzYdovqLDU/mEnNGsxXPGI1zGN3tOW09wPA/tEkwpgGV6RUjT aXABaaxfeY58JoxKm9dkSiZPFEStze7muFkdHKgrGx3j/qyUJQCYRiRxgYFzLSq9C/BEG5 /uGcf3B7+dBwbM/kR1T3ywIbEIm6N8tgXRQXKDRN2/rsykDuGTk9t5einreOI9rIg7G+Z9 t/C7xlQucV7GxciZfHG+X+GqOY/BJz1USAEPEqZGAbuKwqGizCrh8XLKcnl/7w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20161025 header.b=aGE0NOkF; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 2607:5300:201:3100::1657 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -0.98 Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20161025 header.b=aGE0NOkF; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 2607:5300:201:3100::1657 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: E80371451D X-Spam-Score: -0.98 X-Migadu-Scanner: scn1.migadu.com X-TUID: 5Kzu3Bm342X+ We don't need to check for the order here, that is done in another test. Signed-off-by: Felipe Contreras --- test/T395-ruby.sh | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/test/T395-ruby.sh b/test/T395-ruby.sh index e828efed..9298bc9e 100755 --- a/test/T395-ruby.sh +++ b/test/T395-ruby.sh @@ -20,21 +20,17 @@ test_ruby() { } test_begin_subtest "compare thread ids" -notmuch search --sort=oldest-first --output=threads tag:inbox > EXPECTED +notmuch search --output=threads tag:inbox > EXPECTED test_ruby <<"EOF" -q = db.query('tag:inbox') -q.sort = Notmuch::SORT_OLDEST_FIRST -q.search_threads.each do |t| +db.query('tag:inbox').search_threads.each do |t| puts 'thread:%s' % t.thread_id end EOF test_begin_subtest "compare message ids" -notmuch search --sort=oldest-first --output=messages tag:inbox > EXPECTED +notmuch search --output=messages tag:inbox > EXPECTED test_ruby <<"EOF" -q = db.query('tag:inbox') -q.sort = Notmuch::SORT_OLDEST_FIRST -q.search_messages.each do |m| +db.query('tag:inbox').search_messages.each do |m| puts 'id:%s' % m.message_id end EOF -- 2.32.0.rc0