summaryrefslogtreecommitdiffstats
path: root/tests/ts/cal
Commit message (Collapse)AuthorAgeFilesLines
* tests: add cal --span testsKarel Zak2018-08-071-1/+6
| | | | | Addresses: https://github.com/karelzak/util-linux/issues/677 Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: check for test_calKarel Zak2018-08-073-3/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: rewrite cal(1) bigyear testKarel Zak2018-02-022-166/+53Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: use TS_HELPER_CALKarel Zak2018-02-022-4/+10
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: use subtests for weeknum cal(1) testsKarel Zak2018-01-221-55/+23Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: use subtests for weekarg cal(1) testsKarel Zak2018-01-221-115/+49Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* test: use subtests for jan1753 cal(1) testKarel Zak2018-01-221-14/+16
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: merge year cal(1) testsKarel Zak2018-01-222-88/+22Star
| | | | | | | * merge tests * use subtests for cal(1) calls Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: merge 1m and 3m cal(1) testsKarel Zak2018-01-225-240/+64Star
| | | | | | | * merge tests * use subtests for cal(1) calls Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: merge sep1752 cal(1) testsKarel Zak2018-01-222-143/+47Star
| | | | | | | * merge tests * use subtests for cal(1) calls Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: use subtests for sep1752w testKarel Zak2018-01-221-6/+18
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: simplify cal(1) sep1752w testKarel Zak2018-01-221-70/+35Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add cal(1) --week=40 1752Karel Zak2018-01-221-0/+6
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: fix for non-ncurses versionKarel Zak2016-06-093-0/+15
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* cal: check biggest week number correctly when highlightingSami Kerola2015-08-311-0/+26
| | | | | | | This allows Sunday based week 54 be highlighted, and deny week 54 for Monday based weeks when year has only 52 weeks. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* cal: fix January 1753 week number printoutSami Kerola2015-05-181-0/+43
| | | | | | | | | | | | | | | Earlier output was clearly broken. $ cal -w 1 1753 January 1753 Su Mo Tu We Th Fr Sa 51 1 2 3 4 5 6 52 7 8 9 10 11 12 13 52 14 15 16 17 18 19 20 52 21 22 23 24 25 26 27 52 28 29 30 31 Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: never use -o pipefailRuediger Meier2015-04-2114-17/+0Star
| | | | | | | | | | | | | | | | | | | It was hard to find out that pipefail was the reason why our test-suite could have random failures for aribtrary tests, for example the ones which are using ts_device_has_uuid() or ts_mount(). Bash's pipefall option is evil! It may return error for such a simple line like this one $ echo -e "xxx\nyyy" | grep -q "xxx" because the left echo command will get SIGPIPE when grep exits after the first match. So the command line above could return an error eventhough it does exactly what we want. This patch removes any pipefail from our tests. The funny thing is that I couldn't find any case where we relied on this feature anyway. Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
* tests: check commands needed for running a test existSami Kerola2014-03-0714-1/+29
| | | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: avoid executing dirname(1) commandSami Kerola2014-02-1714-14/+14
| | | | | | Bash parameter expansion does the same thing. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: cal(1) is year is limited to signed 32 bit valueSami Kerola2014-02-062-6/+6
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add TERM= to all cal(1) testsKarel Zak2013-10-2211-0/+11
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* cal: added argument option for -w|--week to display that weekTommi Kyntola2013-10-221-0/+131
| | | | | | | | | Because many years have two sections of week 52 or 53, the week that this argument points to is the one that starts during that year (when available). The week number in argument is also highlighted in addition to possibly visible current/defined date highlighting. Signed-off-by: Tommi Kyntola <kynde@iki.fi>
* cal: various tests for week numbersTommi Kyntola2013-10-227-0/+525
| | | | | | | | Current tests were replicated with week numbers and some additional tests for week numbering corner cases were added, too. Signed-off-by: Tommi Kyntola <kynde@iki.fi>
* cal: added two missing testsTommi Kyntola2013-10-222-0/+2
| | | | | | | Bigyear and Sep1752 lacked their were missing their last intended tests along with their expected outputs. Signed-off-by: Tommi Kyntola <kynde@iki.fi>
* tests: improve cal --color testKarel Zak2013-09-261-0/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: check cal works when year is far in futureSami Kerola2013-05-261-0/+95
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add cal day color corner casesSami Kerola2013-05-261-0/+68
| | | | | | | Check that the first, andn last, possible dates and strange Sep 1752 dates are highlighted correctly. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* tests: add calendar reformation checkSami Kerola2013-05-261-0/+95
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* rename util-linux-ng back to util-linuxKarel Zak2010-11-303-3/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: cleanup ts/cal scriptsKarel Zak2009-02-113-11/+6Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: create subdirs for test scriptsKarel Zak2009-02-113-0/+180
Signed-off-by: Karel Zak <kzak@redhat.com>