forked from util-linux/util-linux
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tests: add color schema to cal(1) tests
Signed-off-by: Karel Zak <kzak@redhat.com>
- Loading branch information
Showing
17 changed files
with
123 additions
and
145 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
January 0001 | ||
Su Mo Tu We Th Fr Sa | ||
[7m 1[0m | ||
2 3 4 5 6 7 8 | ||
9 10 11 12 13 14 15 | ||
16 17 18 19 20 21 22 | ||
23 24 25 26 27 28 29 | ||
30 31 | ||
[35m January 0001 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[31m [[48;5;160m[38;5;221m 1[0m[0m | ||
[31m 2[0m[1;33m 3[0m[1;33m 4[0m[1;33m 5[0m[1;33m 6[0m[1;33m 7[0m[31m 8[0m | ||
[31m 9[0m[1;33m 10[0m[1;33m 11[0m[1;33m 12[0m[1;33m 13[0m[1;33m 14[0m[31m 15[0m | ||
[31m16[0m[1;33m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[31m 22[0m | ||
[31m23[0m[1;33m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[31m 29[0m | ||
[31m30[0m[1;33m 31[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
November 9999 December 9999 January 10000 | ||
Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa | ||
1 2 3 4 5 6 1 2 3 4 1 | ||
7 8 9 10 11 12 13 5 6 7 8 9 10 11 2 3 4 5 6 7 8 | ||
14 15 16 17 18 19 20 12 13 14 15 16 17 18 9 10 11 12 13 14 15 | ||
21 22 23 24 25 26 27 19 20 21 22 23 24 25 16 17 18 19 20 21 22 | ||
28 29 30 26 27 28 29 30 [7m31[0m 23 24 25 26 27 28 29 | ||
30 31 | ||
[35m November 9999 December 9999 January 10000 | ||
Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa[0m | ||
[1;33m 1[0m[1;33m 2[0m[1;33m 3[0m[1;33m 4[0m[1;33m 5[0m[31m 6[0m [1;33m 1[0m[1;33m 2[0m[1;33m 3[0m[31m 4[0m [31m 1[0m | ||
[31m 7[0m[1;33m 8[0m[1;33m 9[0m[1;33m 10[0m[1;33m 11[0m[1;33m 12[0m[31m 13[0m [31m 5[0m[1;33m 6[0m[1;33m 7[0m[1;33m 8[0m[1;33m 9[0m[1;33m 10[0m[31m 11[0m [31m 2[0m[1;33m 3[0m[1;33m 4[0m[1;33m 5[0m[1;33m 6[0m[1;33m 7[0m[31m 8[0m | ||
[31m14[0m[1;33m 15[0m[1;33m 16[0m[1;33m 17[0m[1;33m 18[0m[1;33m 19[0m[31m 20[0m [31m12[0m[1;33m 13[0m[1;33m 14[0m[1;33m 15[0m[1;33m 16[0m[1;33m 17[0m[31m 18[0m [31m 9[0m[1;33m 10[0m[1;33m 11[0m[1;33m 12[0m[1;33m 13[0m[1;33m 14[0m[31m 15[0m | ||
[31m21[0m[1;33m 22[0m[1;33m 23[0m[1;33m 24[0m[1;33m 25[0m[1;33m 26[0m[31m 27[0m [31m19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[1;33m 23[0m[1;33m 24[0m[31m 25[0m [31m16[0m[1;33m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[31m 22[0m | ||
[31m28[0m[1;33m 29[0m[1;33m 30[0m [31m26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[1;33m 30[0m[1;33m [[48;5;160m[38;5;221m31[0m[0m [31m23[0m[1;33m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[31m 29[0m | ||
[31m30[0m[1;33m 31[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
1 [7m 2[0m 14 15 16 | ||
17 18 19 20 21 22 23 | ||
24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[1;33m 1[0m[1;33m [[48;5;160m[38;5;221m 2[0m[0m[1;33m 14[0m[1;33m 15[0m[31m 16[0m | ||
[31m17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[31m24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
1 2 14 15 16 | ||
17 18 19 20 21 22 23 | ||
24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[1;33m 1[0m[1;33m 2[0m[1;33m 14[0m[1;33m 15[0m[31m 16[0m | ||
[31m17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[31m24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
1 2 14 15 16 | ||
17 18 19 20 21 22 23 | ||
24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[1;33m 1[0m[1;33m 2[0m[1;33m 14[0m[1;33m 15[0m[31m 16[0m | ||
[31m17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[31m24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
1 2 [7m14[0m 15 16 | ||
17 18 19 20 21 22 23 | ||
24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[1;33m 1[0m[1;33m 2[0m[1;33m [[48;5;160m[38;5;221m14[0m[0m[1;33m 15[0m[31m 16[0m | ||
[31m17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[31m24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
February 2023 | ||
Su 5 12 19 26 | ||
Mo 6 13 20 27 | ||
Tu 7 14 21 28 | ||
We 1 8 [7m15[0m 22 | ||
Th 2 9 16 23 | ||
Fr 3 10 17 24 | ||
Sa 4 11 18 25 | ||
[35m February 2023 [0m | ||
[35mSu[0m [31m 5[0m[31m 12[0m[31m 19[0m[31m 26[0m | ||
[35mMo[0m [1;33m 6[0m[1;33m 13[0m[1;33m 20[0m[1;33m 27[0m | ||
[35mTu[0m [1;33m 7[0m[1;33m 14[0m[1;33m 21[0m[1;33m 28[0m | ||
[35mWe[0m[1;33m 1[0m[1;33m 8[0m[1;33m [[48;5;160m[38;5;221m15[0m[0m[1;33m 22[0m | ||
[35mTh[0m[1;33m 2[0m[1;33m 9[0m[1;33m 16[0m[1;33m 23[0m | ||
[35mFr[0m[1;33m 3[0m[1;33m 10[0m[1;33m 17[0m[1;33m 24[0m | ||
[35mSa[0m[31m 4[0m[31m 11[0m[31m 18[0m[31m 25[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
February 2023 | ||
Su 5 12 19 26 | ||
Mo 6 13 20 27 | ||
Tu 7 14 21 28 | ||
We 1 8 [7m15[0m 22 | ||
Th 2 9 16 23 | ||
Fr 3 10 17 24 | ||
Sa 4 11 18 25 | ||
5 6 7 8 9 | ||
[35m February 2023 [0m | ||
[35mSu[0m [31m 5[0m[31m 12[0m[31m 19[0m[31m 26[0m | ||
[35mMo[0m [1;33m 6[0m[1;33m 13[0m[1;33m 20[0m[1;33m 27[0m | ||
[35mTu[0m [1;33m 7[0m[1;33m 14[0m[1;33m 21[0m[1;33m 28[0m | ||
[35mWe[0m[1;33m 1[0m[1;33m 8[0m[1;33m [[48;5;160m[38;5;221m15[0m[0m[1;33m 22[0m | ||
[35mTh[0m[1;33m 2[0m[1;33m 9[0m[1;33m 16[0m[1;33m 23[0m | ||
[35mFr[0m[1;33m 3[0m[1;33m 10[0m[1;33m 17[0m[1;33m 24[0m | ||
[35mSa[0m[31m 4[0m[31m 11[0m[31m 18[0m[31m 25[0m | ||
[32m 5[0m [32m 6[0m [32m 7[0m [32m 8[0m [32m 9[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
January 0001 | ||
Su Mo Tu We Th Fr Sa | ||
1 [7m 1[0m | ||
2 2 3 4 5 6 7 8 | ||
3 9 10 11 12 13 14 15 | ||
4 16 17 18 19 20 21 22 | ||
5 23 24 25 26 27 28 29 | ||
6 30 31 | ||
[35m January 0001 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[32m 1[0m [31m [[48;5;160m[38;5;221m 1[0m[0m | ||
[32m 2[0m[31m 2[0m[1;33m 3[0m[1;33m 4[0m[1;33m 5[0m[1;33m 6[0m[1;33m 7[0m[31m 8[0m | ||
[32m 3[0m[31m 9[0m[1;33m 10[0m[1;33m 11[0m[1;33m 12[0m[1;33m 13[0m[1;33m 14[0m[31m 15[0m | ||
[32m 4[0m[31m 16[0m[1;33m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[31m 22[0m | ||
[32m 5[0m[31m 23[0m[1;33m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[31m 29[0m | ||
[32m 6[0m[31m 30[0m[1;33m 31[0m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
November 9999 December 9999 January 10000 | ||
Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa | ||
45 1 2 3 4 5 6 49 1 2 3 4 1 1 | ||
46 7 8 9 10 11 12 13 50 5 6 7 8 9 10 11 2 2 3 4 5 6 7 8 | ||
47 14 15 16 17 18 19 20 51 12 13 14 15 16 17 18 3 9 10 11 12 13 14 15 | ||
48 21 22 23 24 25 26 27 52 19 20 21 22 23 24 25 4 16 17 18 19 20 21 22 | ||
49 28 29 30 53 26 27 28 29 30 [7m31[0m 5 23 24 25 26 27 28 29 | ||
6 30 31 | ||
[35m November 9999 December 9999 January 10000 | ||
Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa Su Mo Tu We Th Fr Sa[0m | ||
[32m45[0m [1;33m 1[0m[1;33m 2[0m[1;33m 3[0m[1;33m 4[0m[1;33m 5[0m[31m 6[0m [32m49[0m [1;33m 1[0m[1;33m 2[0m[1;33m 3[0m[31m 4[0m [32m 1[0m [31m 1[0m | ||
[32m46[0m[31m 7[0m[1;33m 8[0m[1;33m 9[0m[1;33m 10[0m[1;33m 11[0m[1;33m 12[0m[31m 13[0m [32m50[0m[31m 5[0m[1;33m 6[0m[1;33m 7[0m[1;33m 8[0m[1;33m 9[0m[1;33m 10[0m[31m 11[0m [32m 2[0m[31m 2[0m[1;33m 3[0m[1;33m 4[0m[1;33m 5[0m[1;33m 6[0m[1;33m 7[0m[31m 8[0m | ||
[32m47[0m[31m 14[0m[1;33m 15[0m[1;33m 16[0m[1;33m 17[0m[1;33m 18[0m[1;33m 19[0m[31m 20[0m [32m51[0m[31m 12[0m[1;33m 13[0m[1;33m 14[0m[1;33m 15[0m[1;33m 16[0m[1;33m 17[0m[31m 18[0m [32m 3[0m[31m 9[0m[1;33m 10[0m[1;33m 11[0m[1;33m 12[0m[1;33m 13[0m[1;33m 14[0m[31m 15[0m | ||
[32m48[0m[31m 21[0m[1;33m 22[0m[1;33m 23[0m[1;33m 24[0m[1;33m 25[0m[1;33m 26[0m[31m 27[0m [32m52[0m[31m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[1;33m 23[0m[1;33m 24[0m[31m 25[0m [32m 4[0m[31m 16[0m[1;33m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[31m 22[0m | ||
[32m49[0m[31m 28[0m[1;33m 29[0m[1;33m 30[0m [32m53[0m[31m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[1;33m 30[0m[1;33m [[48;5;160m[38;5;221m31[0m[0m [32m 5[0m[31m 23[0m[1;33m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[31m 29[0m | ||
[32m 6[0m[31m 30[0m[1;33m 31[0m |
10 changes: 5 additions & 5 deletions
10
tests/expected/cal/colorw-reformation-corner-cases-1-week-numbers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
36 1 [7m 2[0m 14 15 16 | ||
37 17 18 19 20 21 22 23 | ||
38 24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[32m36[0m [1;33m 1[0m[1;33m [[48;5;160m[38;5;221m 2[0m[0m[1;33m 14[0m[1;33m 15[0m[31m 16[0m | ||
[32m37[0m[31m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[32m38[0m[31m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
10 changes: 5 additions & 5 deletions
10
tests/expected/cal/colorw-reformation-corner-cases-2-week-numbers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
36 1 2 14 15 16 | ||
37 17 18 19 20 21 22 23 | ||
38 24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[32m36[0m [1;33m 1[0m[1;33m 2[0m[1;33m 14[0m[1;33m 15[0m[31m 16[0m | ||
[32m37[0m[31m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[32m38[0m[31m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
10 changes: 5 additions & 5 deletions
10
tests/expected/cal/colorw-reformation-corner-cases-3-week-numbers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
36 1 2 14 15 16 | ||
37 17 18 19 20 21 22 23 | ||
38 24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[32m36[0m [1;33m 1[0m[1;33m 2[0m[1;33m 14[0m[1;33m 15[0m[31m 16[0m | ||
[32m37[0m[31m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[32m38[0m[31m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
10 changes: 5 additions & 5 deletions
10
tests/expected/cal/colorw-reformation-corner-cases-4-week-numbers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
September 1752 | ||
Su Mo Tu We Th Fr Sa | ||
36 1 2 [7m14[0m 15 16 | ||
37 17 18 19 20 21 22 23 | ||
38 24 25 26 27 28 29 30 | ||
[35m September 1752 | ||
Su Mo Tu We Th Fr Sa[0m | ||
[32m36[0m [1;33m 1[0m[1;33m 2[0m[1;33m [[48;5;160m[38;5;221m14[0m[0m[1;33m 15[0m[31m 16[0m | ||
[32m37[0m[31m 17[0m[1;33m 18[0m[1;33m 19[0m[1;33m 20[0m[1;33m 21[0m[1;33m 22[0m[31m 23[0m | ||
[32m38[0m[31m 24[0m[1;33m 25[0m[1;33m 26[0m[1;33m 27[0m[1;33m 28[0m[1;33m 29[0m[31m 30[0m | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
workday yellow | ||
weekend red | ||
today \e[48;5;160m\e[38;5;221 | ||
header magenta | ||
weeks green | ||
weeknumber blue |