Skip to content

Commit 82246e0

Browse files
committed
Sync with 2.9.2
* maint: Git 2.9.2 t0006: skip "far in the future" test when unsigned long is not long enough
2 parents 75676c8 + e634160 commit 82246e0

File tree

5 files changed

+33
-4
lines changed

5 files changed

+33
-4
lines changed

Documentation/RelNotes/2.9.2.txt

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
Git v2.9.2 Release Notes
2+
========================
3+
4+
Fixes since v2.9.1
5+
------------------
6+
7+
* A fix merged to v2.9.1 had a few tests that are not meant to be
8+
run on platforms without 64-bit long, which caused unnecessary
9+
test failures on them because we didn't detect the platform and
10+
skip them. These tests are now skipped on platforms that they
11+
are not applicable to.
12+
13+
No other change is included in this update.

Documentation/git.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,10 @@ unreleased) version of Git, that is available from the 'master'
4343
branch of the `git.git` repository.
4444
Documentation for older releases are available here:
4545

46-
* link:v2.9.1/git.html[documentation for release 2.9.1]
46+
* link:v2.9.2/git.html[documentation for release 2.9.2]
4747

4848
* release notes for
49+
link:RelNotes/2.9.2.txt[2.9.2],
4950
link:RelNotes/2.9.1.txt[2.9.1],
5051
link:RelNotes/2.9.0.txt[2.9].
5152

help.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,12 @@ int cmd_version(int argc, const char **argv, const char *prefix)
419419
* with external projects that rely on the output of "git version".
420420
*/
421421
printf("git version %s\n", git_version_string);
422+
while (*++argv) {
423+
if (!strcmp(*argv, "--build-options")) {
424+
printf("sizeof-long: %d\n", (int)sizeof(long));
425+
/* NEEDSWORK: also save and output GIT-BUILD_OPTIONS? */
426+
}
427+
}
422428
return 0;
423429
}
424430

t/t0006-date.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ check_show () {
3131
format=$1
3232
time=$2
3333
expect=$3
34-
test_expect_${4:-success} "show date ($format:$time)" '
34+
test_expect_success $4 "show date ($format:$time)" '
3535
echo "$time -> $expect" >expect &&
3636
test-date show:$format "$time" >actual &&
3737
test_cmp expect actual
@@ -50,8 +50,8 @@ check_show iso-local "$TIME" '2016-06-15 14:13:20 +0000'
5050

5151
# arbitrary time absurdly far in the future
5252
FUTURE="5758122296 -0400"
53-
check_show iso "$FUTURE" "2152-06-19 18:24:56 -0400"
54-
check_show iso-local "$FUTURE" "2152-06-19 22:24:56 +0000"
53+
check_show iso "$FUTURE" "2152-06-19 18:24:56 -0400" LONG_IS_64BIT
54+
check_show iso-local "$FUTURE" "2152-06-19 22:24:56 +0000" LONG_IS_64BIT
5555

5656
check_parse() {
5757
echo "$1 -> $2" >expect

t/test-lib.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1111,3 +1111,12 @@ run_with_limited_cmdline () {
11111111
}
11121112

11131113
test_lazy_prereq CMDLINE_LIMIT 'run_with_limited_cmdline true'
1114+
1115+
build_option () {
1116+
git version --build-options |
1117+
sed -ne "s/^$1: //p"
1118+
}
1119+
1120+
test_lazy_prereq LONG_IS_64BIT '
1121+
test 8 -le "$(build_option sizeof-long)"
1122+
'

0 commit comments

Comments
 (0)