taskwarrior/test
2015-10-23 10:38:40 -04:00
..
basetest tests: Add export_one and latest helpers to the Task test interface 2015-09-05 14:33:02 -04:00
json
simpletap TAP: Don't fail on errors during setUpClass 2015-07-23 17:42:41 +01:00
test_certs Certs 2015-01-19 18:25:21 -05:00
test_hooks Tests: Add failing on-modify hook 2015-09-04 21:39:08 +02:00
.gitignore Test: Merged t3.t.cpp into t.t.cpp 2015-10-23 10:19:17 -04:00
abbreviation.t Test: Merged bug.1006.t into abbreviation.t 2015-10-23 08:48:20 -04:00
add.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
alias.t Test: Merged bug.1031.t into alias.t 2015-10-23 08:50:18 -04:00
annotate.t Test: Merged bug.annotate.t into annotate.t 2015-10-23 09:00:21 -04:00
append.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
args.t Test: Merged args.1.t into args.t 2015-10-23 09:15:39 -04:00
autocomplete.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
bash_completion.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
bash_tap.sh Tests: Update bash_tap.sh 2015-07-30 17:39:16 +02:00
bash_tap_tw.sh Test: Remove default dateformat for bash_tap.sh tests 2015-10-15 17:43:11 +02:00
bulk.t Test: Merged bug.bulk.t into bulk.t 2015-10-23 09:06:49 -04:00
burndown.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
calc.t Test: Merged bug.1254.t into calc.t 2015-10-23 08:57:26 -04:00
calendar.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
caseless.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
CMakeLists.txt Test: Merged t3.t.cpp into t.t.cpp 2015-10-23 10:19:17 -04:00
col.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
color.cmd.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
color.rules.t Test: Corrected system name for FreeBSD 2015-09-07 12:09:41 -04:00
color.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
columns.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
completed.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
config.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
configuration.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
confirmation.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
context.t Test: Modified timeout values 2015-09-06 13:09:11 -04:00
conversion Test: Fixed error in conversion now there are no more bug.*.t scripts 2015-10-23 09:19:45 -04:00
count.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
custom.config.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
custom.recur_ind.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
custom.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
custom.tag_ind.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
date.iso.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
dateformat.t Test: Merged bug.986.t into dateformat.t 2015-10-23 08:41:51 -04:00
dates.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
datesort.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
datetime-negative.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
debug.t Docs: Updated man page regarding 'debug.parser' values 2015-09-07 12:33:53 -04:00
default.t Test: Merged default.command.t into default.t 2015-10-23 09:21:29 -04:00
delete.t Test: Modified timeout values 2015-09-06 13:09:11 -04:00
denotate.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
dependencies.t Test: Merged bug.697.t into dependencies.t 2015-10-23 08:19:56 -04:00
diag.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
diag_color.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
dom.t Test: Fixed broken test 2015-09-07 16:06:39 -04:00
due.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
duplicate.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
edit.t Test: Removed obsolete 'edit' test 2015-09-07 10:48:21 -04:00
encoding.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
enpassant.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
eval.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
export.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.559.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.725.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.891.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.1013.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.1061.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.default.project.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.print.empty.columns.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
feature.recurrence.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
filter.t Test: Merged bug.before.t into filter.t 2015-10-23 09:09:32 -04:00
fontunderline.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
format.t Test: Merged countdown.t into format.t 2015-10-23 09:32:26 -04:00
fs.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
gc.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
helpers.t Test: Merged completion.t into helpers.t 2015-10-23 08:45:58 -04:00
history.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
hooks.env.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
hooks.on-add.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
hooks.on-exit.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
hooks.on-launch.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
hooks.on-modify.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
hyphenate.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
i18n.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
ids.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
import.t TW-1716: on-modify hooks fail if date.iso is not set 2015-10-18 10:47:25 -04:00
info.t Test: Merged bug.649.t into recurrence.t 2015-10-23 07:14:43 -04:00
iso8601d.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
iso8601p.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
json.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
json_test.cpp Cleanup: Combined File, Path and Directory into FS 2015-05-25 10:11:41 -04:00
json_test.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
lexer.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
limit.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
list.all.projects.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
list.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
log.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
math.t Test: Merged bug.851.t into math.t 2015-10-23 08:29:51 -04:00
msg.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
nag.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
nibbler.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
obfuscate.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
oldest.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
operators.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
overdue.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
partial.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
prepend.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
pri_sort.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
problems Test: Allow .exe in file test names 2015-09-15 22:07:18 -04:00
project.t Test: Merged subproject.t into project.t 2015-10-23 09:30:21 -04:00
quotes.t Test: Merged tw-268.t into quotes.t 2015-10-23 10:38:40 -04:00
rc.override.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
README Docs: Removed false statement from doc 2015-09-15 17:02:59 -04:00
recurrence.t Test: Merged bug.annual.t into recurrence.t 2015-10-23 09:10:56 -04:00
reports.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
run_all problems: Return non-zero code when some tests fail 2015-09-11 07:50:37 -04:00
rx.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
search.t Docs: Updated man page regarding 'debug.parser' values 2015-09-07 12:33:53 -04:00
sequence.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
shell.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
show.t Test: Fixed test broken by change in verbose default 2015-09-20 19:20:48 -04:00
sorting.t Sorting: All dates now sort the same as 'due' dates 2015-09-08 17:57:25 -04:00
special.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
start.t Test: Merged feature.608.t into start.t 2015-10-23 10:22:23 -04:00
stats.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
stress_test Test: More Python 3 compatibility changes in accessory files 2015-07-17 19:27:58 +01:00
substitute.t Test: Merged bug.649.t into recurrence.t 2015-10-23 07:14:43 -04:00
sugar.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
summary.t Test: Renamed bug.summary.t to summary.t 2015-10-23 09:07:37 -04:00
t.t.cpp Test: Merged t3.t.cpp into t.t.cpp 2015-10-23 10:19:17 -04:00
tag.t Test: Merged bug.818.t into tag.t 2015-10-23 08:20:03 -04:00
taskrc.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tdb2.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
template.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
test.cpp Test: Added missing include for Cygwin 2015-07-01 18:20:28 -04:00
test.h Tests: Added color to the C++ tests 2015-07-01 16:12:48 -04:00
text.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
timesheet.t Test: Fixed test that tried to use a floating point epoch date 2015-09-29 21:40:59 -04:00
tw-20.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-46.t TW-1688: task fails to import 2015-09-11 07:49:29 -04:00
tw-262.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-295.t Docs: Updated man page regarding 'debug.parser' values 2015-09-07 12:33:53 -04:00
tw-1262.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1300.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1306.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1319.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1359.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1377.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1379.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1381.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1414.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1418.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1419.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1424.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1430.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1436.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1438.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1441.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1445.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1447.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1452.t tests: Bring tw-1452 and tw-1481 back to life 2015-09-05 14:34:29 -04:00
tw-1456.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1468.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1469.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1475.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1479.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1481.t tests: Bring tw-1452 and tw-1481 back to life 2015-09-05 14:34:29 -04:00
tw-1486.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1510.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1521.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1527.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1542.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1549.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1575.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1609.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1612.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1617.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1620.t TW-1620: Dateformat wrongly interpreted 2015-10-07 08:13:27 -04:00
tw-1622.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1627.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1630.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1634.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
tw-1637.t Test: Added explanation 2015-07-25 14:06:32 -04:00
tw-1643.t TW-1643: Add failing test 2015-07-30 13:13:38 +02:00
tw-1687.t TW-1687: task add due:som appears to be interpreted as 'someday' 2015-09-06 15:48:05 -04:00
tw-1688.t Test: Simplify tw-1688.t 2015-09-11 17:22:00 +02:00
tw-1715.t TW-1715: No UDA needed, same problem with core attributes 2015-10-16 10:08:13 +02:00
uda.t Test: Merged tw-21.t into uda.t 2015-10-23 10:20:25 -04:00
uda_orphan.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
uda_report.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
uda_sort.t tests: Add test for default sorting of UDA strings 2015-09-13 10:52:23 -04:00
undo.t Test: Modified error message expectation 2015-09-06 14:59:43 -04:00
unicode.t Docs: Updated man page regarding 'debug.parser' values 2015-09-07 12:33:53 -04:00
unique.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
upgrade.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
urgency.t Test: Merged bug.837.t into urgency.t 2015-10-23 08:25:52 -04:00
urgency_inherit.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
utf8.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
util.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
uuid.t Test: Merged bug.954.t into uuid.t 2015-10-23 08:39:14 -04:00
variant_add.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_and.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_cast.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_divide.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_equal.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_exp.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_gt.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_gte.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_inequal.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_lt.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_lte.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_match.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_math.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_modulo.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_multiply.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_nomatch.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_not.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_or.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_partial.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_subtract.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
variant_xor.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
verbose.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00
version.t Test: Make version test compatible with non-beta releases 2015-10-22 13:43:40 +02:00
view.t.cpp Test: Cleanup prep for '-Wextra' 2015-10-16 15:55:17 -04:00
wait.t tests: State explicit filetype for .t python files 2015-09-05 14:22:52 -04:00

README
======

This is the task.git/test/README file, and contains notes about the Taskwarrior
test suite.


Running Tests
-------------

TL;DR  cd test && make && ./run_all && ./problems

All unit tests produce TAP (Test Anything Protocol) output, and are run by the
'run_all' test harness.

The 'run_all' script produces an 'all.log' file which is the accumulated output
of all tests. Before executing 'run_all' you need to compile the C++ unit
tests, by running 'make' in the 'test' directory.

The script 'problems' will list all the tests that fail, with a count of the
failing tests, once you have run all the tests and produced an 'all.log' file.

Any TAP harness may be used.

Note that adding the '--serial' option to ./run_all, all tests are executed
serially.  The default runs Python, C++ and Bash tests in parallel. Using
'--serial' will make for a slower test run.


Architecture
------------

There are three varieties of tests:

  * C++ unit tests that test low-level object interfaces. These are typically
    very fast tests, and are exhaustive in nature.

  * Python unit tests that are at the highest level, exercising the command
    line, hooks and syncing. There is an example, 'template.t', that shows how
    to perform various high level tests.

  * Bash unit tests, one test per file, using the bash_tap_tw.sh script. These
    tests are small, quick tests, not intended to be permanent.

All tests are named with the pattern '*.t', and any other forms are not run by
the test harness. Additionally a test must be set executable (chmod +x) for it
to be run. In the case of Python tests one can still run them manually by
launching them with 'python test.t' or simply './test.t'. It also allows us to
keep tests submitted for bugs that are not scheduled to be fixed in the
upcoming release, and we don't want the failing tests to prevent us from seeing
100% pass rate for the bugs we *have* fixed.


Goals
-----

The test suite is evolving, and becoming a better tool for determining whether
code is ready for release. There are goals that shape these changes, and they
are:

  * Increase test coverage by testing more features, more thoroughly. The test
    coverage level is (as of 2015-07-24) at 86.5%.

  * Write fewer bug regression tests. Over time, bug regression tests are less
    useful than feature tests, and more likely to contain overlapping coverage.

  * Eliminate obsolete tests, which are tests that have overlapping coverage.
    This means migrate bug-specific tests to feature tests.


What Makes a Good Test
----------------------

A good test ensures that a feature is functioning as expected, and contains
both positive and negative aspects, or in other words looks for expected
behavior as well as looking for the absence of unexpected behavior.


Conventions for writing a test
------------------------------

If you wish to contribute tests, please consider the following guidelines:

  * Tests created after bugs or feature requests should (ideally) have an entry
    on https://bug.tasktools.org/ and should include the issue ID in a
    docstring or comment.

  * Tests should be added to the file that best matches the "thing" being
    tested. For instance, a test on filters should live in filter.t

  * Class and method names should be descriptive of what they are testing.
    Example: TestFilterOnReports

  * Docstrings on Python tests are mandatory. The first line is used as title
    of the test.

  * Extra information and details should go into multi-line docstrings or
    comments.

  * Python tests for bugs or features not yet fixed/implemented should be
    decorated with: @unittest.skip("WaitingFor TW-xxxx"). We would rather have
    a live test that is skipped, than no test.


How to Submit a Test Change/Addition
------------------------------------

Mail it to support@taskwarrior.org, or attach it to an open bug.


Wisdom
------

Here are some guildelines that may help:

  * If there are any lexer.t tests failing, then ignore all the others and fix
    these first. They are fundamental and affect everything else. One Lexer
    failure can cause 30 symptomatic failures, and addressing any of those is
    wrong.

  * If any of the C++ tests fail, fix them next, for the same reason as above.

  * If you are about to fix a bug, and no tests are failing, add tests that fail
    in a script named tw-XXXX.t. Later, someone will incorporate that test
    script into higher-level feature tests.

  * If the command line parser is not working, always blame the Lexer.

  * While the lowest level (C++) tests should be exhaustive, higher level tests
    should not do the same by iterating over the entire problem space. It is a
    waste of time.

  * If you find that you are combining two features into one test, you are
    probably doing it wrong.

  * If you add a feature, then add a test to prove it works, also add a test to
    prove it doesn't simultaneously generate errors. Furthermore test that with
    the feature disabled, or command line arguments missing, appropriate errors
    are reported.


TODO
----

For anyone looking for test-related tasks to take on, here are some suggestions:

  * Find and eliminate duplicate tests.

  * Using <attribute>.startswith:<value> with rc.regex:off still uses regex.

  * Crazy dateformat values are not tested.

  * Invalid UTF8 is not tested.

  * All the attribute modifiers need to be tested, only a few are.

  * Aliases are not well tested, and fragile.

---