aboutsummaryrefslogtreecommitdiffstats
path: root/test/range-001.sh
Commit message (Collapse)AuthorAgeFilesLines
* Implement test initialization properlyLukas Fleischer2014-07-081-1/+1
| | | | | | | Make test-init.sh work even if tests are executed from another directory. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
* test/: Add default values for configuration variablesLukas Fleischer2013-02-271-0/+2
| | | | | | | | | | | Add a small helper script called "test-init.sh" that is sourced in each test case and initializes the CALCURSE and DATA_DIR environment variables. Update the test suite README to point out that setting these environment variables is no longer required. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
* test/: Use `faketime -f`Lukas Fleischer2012-12-221-1/+1
| | | | | | | | | | | | Use the advanced timestamp specification format for libfaketime. Before using that, some tests failed on 32-bit systems due to integer overflows. It seems like faketime translates absolute dates to relative dates by default. Moreover, libfaketime is not able to handle relative dates that exceed the maximum value of a signed integer. Using "-f" skips the conversion to relative dates. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
* test/: Do not error out if libfaketime is missingLukas Fleischer2012-12-221-1/+1
| | | | | | | | If the faketime library is missing, show a warning and skip the test. However, do not error out to make sure the test suite is able to terminate successfully on systems without libfaketime. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
* test/: Run calcurse in read-only modeLukas Fleischer2012-02-241-1/+1
| | | | | | | | We don't change any configuration nor do we modify items here, so we can safely invoke calcurse in read-only mode. Fixes a couple of permission errors seen with `make distcheck`. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
* test/: Use correct calcurse binary and data dirLukas Fleischer2012-02-241-1/+1
| | | | | | | | | | We really don't want to use the calcurse(1) binary from "$PATH" here. Introduce an environment variable "$CALCURSE" which can be used specify the binary to use and set this variable to the binary located in the build directory by default. Similarly, add another environment variable "$DATA_DIR" that can be used to specify a data directory. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
* test/: Add test cases for "-d" and "-s"/"-r"Lukas Fleischer2012-01-221-0/+19
* day-001.sh: Compare output of "-d<date>" with hardcoded data. * day-002.sh: Compare output of "-d<num>" with hardcoded data. * day-003.sh: Compare output of "-d<num>" with "-s<date> -r<num>". * range-001.sh: Compare output of "-r" with hardcoded data. * range-002.sh: Compare output of "-r<num>" with hardcoded data. * range-003.sh: Compare output of "-r<num>" with "-s<date> -r<num>". Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>