From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 3CEFD431FDC for ; Sat, 22 Feb 2014 14:26:05 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" X-Spam-Flag: NO X-Spam-Score: -0.7 X-Spam-Level: X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id NlM91JNGYDZb for ; Sat, 22 Feb 2014 14:26:00 -0800 (PST) Received: from mail-ea0-f179.google.com (mail-ea0-f179.google.com [209.85.215.179]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id CAB54431FCF for ; Sat, 22 Feb 2014 14:25:56 -0800 (PST) Received: by mail-ea0-f179.google.com with SMTP id q10so2303975ead.24 for ; Sat, 22 Feb 2014 14:25:54 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=bAiHRWWjZsaElIhfrkzflCVDZxrmhvUGvplkzBUpNM0=; b=cyQ5OYgNDNn8FXLtSCPLYKV9bAVntDeNMBfVgHoNAj7i1Y/7klbhru8mQ+TUDOWhk1 8NcNLD85PR7Cq08M6VNDhsKZ+bHzpMTfa2aT6zrmpk/i1J4tEuJWK+F0ZmANhbab3Kun KaPFzyw1qUtP+wSkjaxkQc9bC13CwyqpdGNxdwnnd0cNu0upLwyGvHBXRtF1nBC7hx+L 58KohMIOXKfipIOUBtGvOKvTGL0RMBfI4cEfhcVAEF5i/APaT00KYq/VdqCe9F/JXIT5 5Zj6GwDix/Ow90jtkp4ga40xsiHBlVKvmKGDz+/JLOLUX60xJcOZqZ4zGqHzEI2T8fF9 QU+w== X-Gm-Message-State: ALoCoQlhlTuN7YaKzkWZsBCQ4WipEngLnUfSV5SIcMa3ITQUCC60flB8qiACxCHHqiF5GaEEq5GX X-Received: by 10.14.3.72 with SMTP id 48mr16660498eeg.34.1393107954219; Sat, 22 Feb 2014 14:25:54 -0800 (PST) Received: from localhost (dsl-hkibrasgw2-58c36f-91.dhcp.inet.fi. [88.195.111.91]) by mx.google.com with ESMTPSA id j42sm43781823eep.21.2014.02.22.14.25.53 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sat, 22 Feb 2014 14:25:53 -0800 (PST) From: Jani Nikula To: notmuch@notmuchmail.org Subject: [PATCH v2 03/13] test: make insert test use the path: prefix Date: Sun, 23 Feb 2014 00:25:34 +0200 Message-Id: X-Mailer: git-send-email 1.8.5.3 In-Reply-To: References: In-Reply-To: References: X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Feb 2014 22:26:05 -0000 This is a more strict test for the insert test. --- test/T070-insert.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test/T070-insert.sh b/test/T070-insert.sh index e8dc4c099ed1..5de5da43cebb 100755 --- a/test/T070-insert.sh +++ b/test/T070-insert.sh @@ -126,14 +126,14 @@ test_expect_equal "$dirname" "$MAIL_DIR/new" test_begin_subtest "Insert message into folder" gen_insert_msg notmuch insert --folder=Drafts < "$gen_msg_filename" -output=$(notmuch search --output=files folder:Drafts) +output=$(notmuch search --output=files path:Drafts/new) dirname=$(dirname "$output") test_expect_equal "$dirname" "$MAIL_DIR/Drafts/new" test_begin_subtest "Insert message into folder, add/remove tags" gen_insert_msg notmuch insert --folder=Drafts +draft -unread < "$gen_msg_filename" -output=$(notmuch search --output=messages folder:Drafts tag:draft NOT tag:unread) +output=$(notmuch search --output=messages path:Drafts/cur tag:draft NOT tag:unread) test_expect_equal "$output" "id:$gen_msg_id" gen_insert_msg @@ -143,21 +143,21 @@ test_expect_code 1 "Insert message into non-existent folder" \ test_begin_subtest "Insert message, create folder" gen_insert_msg notmuch insert --folder=F --create-folder +folder < "$gen_msg_filename" -output=$(notmuch search --output=files folder:F tag:folder) +output=$(notmuch search --output=files path:F/new tag:folder) basename=$(basename "$output") test_expect_equal_file "$gen_msg_filename" "$MAIL_DIR/F/new/${basename}" test_begin_subtest "Insert message, create subfolder" gen_insert_msg notmuch insert --folder=F/G/H/I/J --create-folder +folder < "$gen_msg_filename" -output=$(notmuch search --output=files folder:F/G/H/I/J tag:folder) +output=$(notmuch search --output=files path:F/G/H/I/J/new tag:folder) basename=$(basename "$output") test_expect_equal_file "$gen_msg_filename" "${MAIL_DIR}/F/G/H/I/J/new/${basename}" test_begin_subtest "Insert message, create existing subfolder" gen_insert_msg notmuch insert --folder=F/G/H/I/J --create-folder +folder < "$gen_msg_filename" -output=$(notmuch count folder:F/G/H/I/J tag:folder) +output=$(notmuch count path:F/G/H/I/J/new tag:folder) test_expect_equal "$output" "2" gen_insert_msg -- 1.8.5.3