From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0r.migadu.com with LMTPS id 8GSfLvJDjWALZgEALuJCtg (envelope-from ) for ; Sat, 01 May 2021 14:05:06 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id 2NFnKvJDjWBDPwAAB5/wlQ (envelope-from ) for ; Sat, 01 May 2021 12:05:06 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [144.217.243.247]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 551B6110C9 for ; Sat, 1 May 2021 14:05:06 +0200 (CEST) Received: from nmbug.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 4C14A271EF; Sat, 1 May 2021 08:05:03 -0400 (EDT) Received: from mail-oo1-xc35.google.com (mail-oo1-xc35.google.com [IPv6:2607:f8b0:4864:20::c35]) by mail.notmuchmail.org (Postfix) with ESMTPS id 732B9271F1 for ; Sat, 1 May 2021 08:05:00 -0400 (EDT) Received: by mail-oo1-xc35.google.com with SMTP id u48-20020a4a97330000b02901fa060b8066so217816ooi.8 for ; Sat, 01 May 2021 05:05:00 -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=5cahol+ayCJGK/RUTL0ydwrTMY2F4d5sz/Mlpi8tbDg=; b=FO/xDyWtb8k9ajjCwj8PDgKgbjVARQ2VfwL0IuHgEYEjKHUxvlWP+OOu4o9FTZq0oC AY387bO+R220DdTDLyRb3yMlt3vtw0WiTdonwWOLOIrKUb2rSyF+JYrGf2bi1hlaXGx7 nwLpHft4AWcPjcQ3S7rwGd9Z6FIMw1w8IquF+TDsipk4iWZPhc4k2/64QQvmkliVMLn1 moBzRBGaNUX2UG0/uyGfUt2pzThX6KVDpVANPECt4zEd+1WZ56mmHagQtM0gL0KQAo4q bfvXV3VDiPE2olfQ5J8IMmFT2xc+KSyjXr3acjSL/OvjofQ8Flb6r9pE0Xe+gvhjPIPT PW1Q== 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=5cahol+ayCJGK/RUTL0ydwrTMY2F4d5sz/Mlpi8tbDg=; b=rUoSql9OBzKbwXcSQLR5byfYqLvJ3Q/geFJoD1pP4vOiHb251DF5hDkUorvOaOFp7L Aj6wQkCEL3h8XOn01HPXFIRIzWPKflqJ5JlG9I3vQwWxB85G2C5DO59AiWEIEENWM7te 3dWn8YtI0gOPTEz6yDxb3Fe7HqasXptBLWfuNVIOjKfZswqzrDL4zloekp1z83itYMqB UrWwMedHQhOvMeyCOenVVRwtFNQbmPC/BfC0TSWojbobVyFbYC/xE+6FhijlTrvO1s9G 6KdpBojQ/yMlJl8y4+fHeSLvvg4Gqw0myTMRvUwdeWE+XvGZYsw6z5g5E1w3kHEqrYsQ jijg== X-Gm-Message-State: AOAM530EkBc40RF17gJBq7XdMxZj05K02E+J04EXogPHitfHW7eznQFi SG40O39K4v/twx0PnplonVjIJgHT7NKlvg== X-Google-Smtp-Source: ABdhPJwm+RlJJaTi6HN5JgNf8jjD0GxEEJJMCkqrLljvrTCc8NVUBoZbS09udI+wBoqohBFi/0S3aw== X-Received: by 2002:a4a:d781:: with SMTP id c1mr8296279oou.44.1619870694530; Sat, 01 May 2021 05:04:54 -0700 (PDT) Received: from localhost ([2806:2f0:4060:638f:a2c5:89ff:fe0c:1151]) by smtp.gmail.com with ESMTPSA id i130sm1514165oif.49.2021.05.01.05.04.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 01 May 2021 05:04:54 -0700 (PDT) From: Felipe Contreras To: notmuch@notmuchmail.org Subject: [PATCH 3/3] test: ruby: simplify basic tests Date: Sat, 1 May 2021 07:04:48 -0500 Message-Id: <20210501120448.484082-4-felipe.contreras@gmail.com> X-Mailer: git-send-email 2.31.0 In-Reply-To: <20210501120448.484082-1-felipe.contreras@gmail.com> References: <20210501120448.484082-1-felipe.contreras@gmail.com> MIME-Version: 1.0 Message-ID-Hash: ZPSGEDDCQY76XCDVRUFFQO5BTXZRXOOW X-Message-ID-Hash: ZPSGEDDCQY76XCDVRUFFQO5BTXZRXOOW 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=1619870706; 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=b+Ujbsfa3jfgxCfyolGDynQVHakPkRv1xZsmtL7s1YE=; b=KrGPoyDSJ13BHZoQ6FuviP13Ix8parO41cU3slxkLIBURSK6CC9GVM0m6O76ZFxip03ae9 w9V97vQH9SPRL5W6iUnqOMWAWi2ELhVkVw49P8ub0xx+MD4w16LmoLiIc5e7uF0XDvlIs4 mRY/ThS5JbFLLzF6N1SZk1cvslj1SpCOF973tShsCpXGjONRWmSbtG5qmQYkRL5XFtBG5W 64fjmcRalf0lfex15TzP7cXzf4ZM0EemFMVw1ae0SdHAM2xVuQ6TUBJM/n0rosmoe16sQb ZHCyOUO0O10iIp2eBqfwV0QeRNyQqpvo2487bWXeoWu6qAD6jX2lBGeKmvJmCA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1619870706; a=rsa-sha256; cv=none; b=IKxns3u/Q8rHzuUyywZsW7oJ49RMQ6shVx43qdizobBLGjttjnWpB2NMCZhMuMBHmOjBcn NR73mUGuhxpf5gtLMjT4pGvi038J0ZTSeQjd78H7QSuJgcuRFZqHvIlACdb+o/jhnMGtcU ryTVO8zD3dvk1Im4CU7HSpWDB78INd77NM0ARkT3cSYfTQFBlHKbAjgOLVrl9O4G57QBJ/ 85XirBpt4JDcJ5zWbXeKdE1OCkENUGOZOQCHufyeuUsvSZkxu0PVQS7W+nLM1S/lBMx8XH FKpwdxdslSPnVo4ZX4bWj5O7eL7qruqPYxm6Dfo49JZzo0o0Uhlfb0yWkE2reA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20161025 header.b="FO/xDyWt"; 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 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -1.00 Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20161025 header.b="FO/xDyWt"; 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 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: 551B6110C9 X-Spam-Score: -1.00 X-Migadu-Scanner: scn0.migadu.com X-TUID: xwjoxJjIDX5W 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.31.0