aboutsummaryrefslogtreecommitdiff
path: root/test/notmuch-test
Commit message (Collapse)AuthorAge
* test: add basic show, search --format=text testsPeter Wang2012-07-09
| | | | | | There didn't seem to be these basic tests for --format=text, as there are for --format=json. These are just the tests from the `json' script, with adjusted expected outputs.
* test: Add tests for 'config' commandPeter Wang2012-04-28
| | | | Start a new test script.
* test: add some exclude testsMark Walters2012-04-07
| | | | | | | | Systematically test the exclude options for search. Also move the search existing exclude tests into the new test. There is some overlap between the two sets of tests but many of the existing ones are there because they triggered bugs in the past so I have kept them to ensure coverage.
* emacs: Tests for user-defined sectionsDaniel Schoepe2012-03-01
| | | | A new file was added for notmuch-hello tests.
* test: add test for hiding Original Message region at beginning of a messageDmitry Kurochkin2012-02-04
| | | | | | | | | | The test is currently broken and will be fixed by a subsequent patch. The patch adds a new file for tests of Emacs notmuch-show view. Based on patch by David Edmondson [1]. [1] id:"1327562380-12894-4-git-send-email-dme@dme.org"
* test: remove ".sh" extension from the recently added Emacs testsDmitry Kurochkin2012-02-03
| | | | | All test files, except for the recently added Emacs tests, do not have ".sh" extension. So remove it from the new test files for consistency.
* test: Add address cleaning tests.David Edmondson2012-01-25
|
* test: Add `test_emacs_expect_t'.David Edmondson2012-01-25
| | | | | | | | | Add a new test function to allow simpler testing of emacs functionality. `test_emacs_expect_t' takes one argument - a lisp expression to evaluate. The test passes if the expression returns `t', otherwise it fails and the output is reported to the tester.
* test: add tests for "notmuch reply" --reply-to=senderMark Walters2012-01-14
|
* test: emacs: test notmuch-wash-subject-to-* functionsJani Nikula2011-12-28
| | | | Signed-off-by: Jani Nikula <jani@nikula.org>
* test: add tests for hooksJani Nikula2011-12-11
| | | | Signed-off-by: Jani Nikula <jani@nikula.org>
* test: tests for command-line-arguments.cDavid Bremner2011-12-08
| | | | | This was needed because no current notmuch code exercises the NOTMUCH_OPT_STRING style arguments.
* Merge branch 'release'David Bremner2011-12-06
|\ | | | | | | | | | | | | Conflicts: NEWS Conflicts resolved by inserting the 0.10.2 stanza before 0.11
| * test: add tests for python bindingsDavid Bremner2011-12-05
| | | | | | | | | | | | We start modestly, with a (slightly modified) test case from Kazuo Teramoto. Originally it just made sure the bindings didn't crash; here we check that by comparing the output with that of notmuch search.
* | Merge branch 'release'David Bremner2011-11-26
|\|
| * test: add simple tests for online helpDavid Bremner2011-11-25
| | | | | | | | Nothing fancy, but we can at least detect segmentation faults.
* | test: make all tests terminable with Ctrl-cTomi Ollila2011-11-18
|/ | | | | | | Some tests don't break when HUP signal is sent tho those (by pressing ctrl-c on the terminal). Therefore, the top-level test script catches the HUP and sends TERM signal to the started test script.
* test: add tests for notmuch search --offset and --limitJani Nikula2011-11-15
| | | | Signed-off-by: Jani Nikula <jani@nikula.org>
* test: add tests for notmuch countJani Nikula2011-11-15
| | | | Signed-off-by: Jani Nikula <jani@nikula.org>
* test: Add a test script for "notmuch tag"Austin Clements2011-11-14
|
* test: Test atomicity of notmuch new.Austin Clements2011-09-12
| | | | | | | This tests notmuch new's ability to recover from arbitrary stopping failures. It interrupts notmuch new after every database commit and, on every resulting database snapshot, re-runs notmuch new to completion and checks that the final database state is invariant.
* test:Folder tags shouldn't match after removal of file in given folderMark Anderson2011-06-29
| | | | | | | | | | | Test for bug. Current stemming support for notmuch adds extra terms to the DB which aren't removed when the file renames are detected. When folder tags are added to a message, Xapian terms for both XFOLDER and ZXFOLDER are generated. When one of the filenames are renamed/removed, only the XFOLDER tags are removed, leaving it possible for a match on a folder: tag that was previously but is no longer a match in the maildir.
* tests: add a test for symbol hiding side effectsDavid Bremner2011-06-23
| | | | | | | | | | | The worry here is that a binary linking with libnotmuch might lose access to Xapian::Error symbols because libnotmuch hides them. We are careful here to create ./fakedb/.notmuch in order to trigger a Xapian exception, and not just a missing file check. Thanks to jrollins and amddragon for suggestions. (cherry picked from commit 66f37f5f6864a988f94ddb893e3a176af57f6c8e)
* tests: Add optional use of timeout utility, if present.David Bremner2011-06-22
| | | | | | | | | | | Each top level test (basic, corpus, etc...) is run with a fixed timeout of 2 minutes. The goal here is to treat a hung test as a failure. The emacs test for sending mail is known to be problematic on the Debian autobuilders. This is both a bandaid fix for that, and a sensible long term feature. (cherry picked from commit 5f99c80e02736c90495558d9b88008a768876b29)
* test: add crypto tests for signature verification and decryptionJameson Graef Rollins2011-05-27
| | | | | | | | | | | | | | | | | | | This adds a new "crypto" test script to the test suite to test PGP/MIME signature verification and message decryption. Included here is a test GNUPGHOME with a test secret key (passwordless), and test for: * signing/verification * signing/verification with full owner trust * verification with signer key unavailable * encryption/decryption * decryption failure with missing key * encryption/decryption + signing/verfifying * reply to encrypted message * verification of signature from revoked key These tests are not expected to pass now, but will as crypto functionality is included.
* test: change "#!/bin/bash" to "#!/usr/bin/env bash" enhances portabilityJoel Borggrén-Franck2011-05-27
| | | | | | Change #!/bin/bash at start of tests to "#!/usr/bin/env bash". That way systems running on bash < 4 can prepend bash >= 4 to path before running the tests.
* test: force deletion of test remnantsJameson Graef Rollins2011-05-23
| | | | | | This keeps the test from failing if only a subset of the remnants were available for deletion, because e.g. only a subset of the tests were run.
* test: allow specifying tests to run with NOTMUCH_TESTS env varJameson Graef Rollins2011-05-23
| | | | | | This is useful for just running a specific subset of tests, ie: NOTMUCH_TESTS=crypto make test
* test: Add a test of "notmuch show" with a multipart messageCarl Worth2011-05-16
| | | | | | | | | | | | This tests "notmuch show" with both --format=text and --format=json on a message with some non-trivial MIME multipart nesting, (multiple parts within a multipart/mixed part which is within a multipart/signed part). The test captures the current behavior (where only the leaf nodes of the MIME structure are emitted as a flat list---the multipart parts are effectively ignored). We plan to soon change the json output at least to emit an actual hierarchy matching the MIME structure, (at which point we will update this test).
* Rename/rewrite the new emacs-forgetfulness test (to emacs-large-search-buffer)Carl Worth2011-03-10
| | | | | | | | The new name is more descriptive of the bug being tested. Also, the test is rewritten slightly so that it's much more plain to see how the bug manifests itself, (that messages are droped from the emacs result at regular intervals). Primarily, this is by collapsing the large blobs used to inflate the message subjects.
* New test: Emacs' forgetfulness.Thomas Schwinge2011-03-10
| | | | Signed-off-by: Thomas Schwinge <thomas@schwinge.name>
* test: Rename and clarify the search-lwn testCarl Worth2011-03-09
| | | | | | | | Now that we understand the bug here, we rename this test to search-insufficient-from-quoting to clarify the bug being exercised, (which occurs when the From: line contains an unquoted '.' character). We also mark these tests as expected failures until the bug gets fixed.
* search: Move lwn tests into their own file.Carl Worth2011-03-09
| | | | | Since it's much easier to debug and fix these if they can be run on their own.
* test: Make it easier to resolve conflicts when adding new testsMichal Sojka2011-01-26
| | | | | | | | | | | Currently, there are two places in the test framework that contain very long list on a single line. Whenever a test is added (or changed) in several branches and these branches are merged, it results in conflict which is hard to resolve because one has to go through the whole long line to find where the conflict is. This patch splits these long lists to several lines so that the conflicts are easier to resolve.
* Add test demonstrating a position overlap bug.Carl Worth2011-01-26
| | | | | | | | | | | | | | | Currently, whenever we call index_terms multiple times for a single field, the term generator is being reset to position 0 each time. This means that with text such as: To: a@b.c, x@y.z one can get a bogus match by searching for: To: a@y.c Thanks to Mark Anderson for reporting the bug, (and providing a nice, minimal test case that inspired what is used here).
* test: Add new tests for folder-based searching.Carl Worth2011-01-15
| | | | | | | | | | This is a new feature which is not implemente yet, so these tests mostly fail currently. A subsequent commit will add the feature and cause these tests to start passing. These tests verify that we can search for containing folders of mail files by word or by phrase and that the search terms are updated correctly when directories are renamed.
* Revert "test: Break on test script (or other) error"Carl Worth2010-12-07
| | | | | | | | This reverts commit f22a7ec1e28d1264cf9d67d78796b8ab22e09a35. Interrupting the test suite due to an actual bug in a test script would be just fine, but interrupting the run of the entire test suite at the first test failure is unacceptable.
* test: Add simple tests for "notmuch search --output=<>"Carl Worth2010-11-23
| | | | | | | | | | | This code simply wasn't being exercised by the test suite before, so this will be useful. Meanwhile, there's currently a bug in "notmuch search --output=tags" in that it doesn't print a final newline. But the current test suite isn't able to catch this bug since the $() construct of the shell doesn't preserve the distinction of whether the final newline is present or not.
* test: Break on test script (or other) errorMichal Sojka2010-11-16
| | | | | | | | | Break notmuch-test whenever a test script returns non-zero status. This happens either when some test from the script fails or when there is an error in the script. This is especially useful in the latter case since the error may not appear in the final aggregated results.
* Tests for maildir synchronizationMichal Sojka2010-11-10
| | | | Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
* Rename "notmuch cat" to "notmuch show --format=raw"Carl Worth2010-11-06
| | | | | | | | | This is part of an effort to avoid proliferation of excessive top-level notmuch commands. Also, "raw" better captures the functionality here, (as opposed to "cat" which is a fairly oblique reference to a bad Unix abbreviation whose metaphor doesn't work here since "notmuch cat" operates only on a single message and hence cannot "con'cat'enate" anything).
* Add 'cat' subcommandMichal Sojka2010-11-05
| | | | | | | | | | | | This command outputs a raw message matched by search term to the standard output. It allows MUAs to access the messages for piping, attachment manipulation, etc. by running notmuch cat rather then directly access the file. This will simplify the MUAs when they need to operate on a remote database. Edited-by: Carl Worth <cworth@cworth.org>: Remove trailing whitespace, add missing "test_done" to new test script to avoid "Unexpected exit" error.
* test: Emit a friendly error message if run with bash < 4.0.Carl Worth2010-10-28
| | | | | | | | | | The bash code in the test suite is using associative arrays which were only added to bash as of release 4.0. If the test suite is run with an older bash, we now immediately error out and explain the situation, (instead of emitting confusing error messages and failing dozens of tests, which is what happened before this change).
* test: Add the most rudimentary testing of the emacs interface.Carl Worth2010-10-22
| | | | | | So far, this is doing nothing more than adding a corpus of email and ensuring that the `notmuch-hello' function produces the desired output.
* test: Fix the search and dump-restore tests to operator on non-empty mail store.Carl Worth2010-09-20
| | | | | We do this with a new add_email_corpus function that establishes a mail store with 50 messages from the notmuch mailing list.
* test: Print section names, and rename all test sectionsCarl Worth2010-09-20
| | | | | | | | Now that we can usefully pass section names via the NOTMUCH_SKIP_TESTS environment variable, it's useful to actually print those names out for the user. Then, since we're now printing these names, let's use nicer names, (not excessively long but also not using abbreviations like "msg").
* test: Fix notmuch-test to pass command-line arguments to sub-scripts.Carl Worth2010-09-20
| | | | The is useful for things like "notmuch-test --valgrind", etc.
* test: Rename all tests to get rid of the ugly numbers in file names.Carl Worth2010-09-17
| | | | | | | The numbers were meaningless, and they made it hard to find a file of interest. Instead, we get the ordering we want by adding an explicit list of tests to run to the notmuch-test script.
* test: Cleanup the test outputCarl Worth2010-09-17
| | | | | | | | | | | | | | | | This makes the new, git-derived test suite report results in a manner similar to the original notmuch test suite. Notable changes include: * No more initial '*' on every line * Only colorize a single word * Don't print useless test numbers * Use "PASS" in place of "ok" * Begin sentences with a capital letter * Print test descriptions for each block * Separate each block of tests with a blank line * Don't summarize counts between each block
* test: Fix test suite to integrate with our non-recursive Makefile system.Carl Worth2010-09-17
| | | | | | | This avoids "make test" emitting messages from three (3!) recursive invocations of make. We change the invocations of the tests themselves to occur directly from the shell script rather than having the shell script invoke make again and using wildcards in the Makefile.