From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: git@vger.kernel.org
Cc: "Taylor Blau" <me@ttaylorr.com>,
"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Subject: [PATCH] t7610: use "file:///dev/null", not "/dev/null", fixes MinGW
Date: Wed, 16 Nov 2022 00:40:14 +0100 [thread overview]
Message-ID: <patch-1.1-21a9cb49299-20221115T233516Z-avarab@gmail.com> (raw)
In-Reply-To: <Y3PrjMLcEGfoHifZ@nand.local>
On MinGW the "/dev/null" is translated to "nul" on command-lines, even
though as in this case it'll never end up referring to an actual file.
So on Windows the fix for the previous "example.com" timeout issue in
8354cf752ec (t7610: fix flaky timeout issue, don't clone from
example.com, 2022-11-05) would yield:
fatal: repo URL: 'nul' must be absolute or begin with ./|../
Let's evade this yet again by prefixing this with "file://", which
makes this pass in the Windows CI.
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
---
On Tue, Nov 15 2022, Taylor Blau wrote:
> On Wed, Nov 09, 2022 at 09:17:25PM -0500, Taylor Blau wrote:
>> On Thu, Nov 10, 2022 at 12:55:30AM +0100, Ævar Arnfjörð Bjarmason wrote:
>> > But we generally just fail some or all of 3..9 pretty fast, and don't
>> > start taking 20 minutes to run the test, when it took 10s before (or
>> > whatever).
>>
>> OK. I still think that in principle this is indistinguishable from not
>> running a setup test to completion.
>>
>> *But*: I'm willing to treat them differently since instead of
>> manifesting in an immediate failure later on in the suite, we hang for a
>> substantial period of time.
>>
>> So I'm content to merge this down, but I don't think it's worth
>> searching out for more of these in the future.
>
> Having merged this down to 'next', it looks like there is some CI
> fallout on the Windows tests, see:
>
> https://github.com/ttaylorr/git/actions/runs/3473324797/jobs/5805324776
>
> I am not sure how I might have caught this earlier not having a Windows
> machine myself. Regardless, let's make sure that it is fixed up before
> this graduates.
Sorry again :( I think my CI was quite queued up at the time, and I
figured surely *this* won't have any porability issues, but forgot
about MinGW's sneaky /dev/null string-replacement behavior.
Windows CI passes with this:
https://github.com/avar/git/actions/runs/3473817195
t/t7610-mergetool.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/t/t7610-mergetool.sh b/t/t7610-mergetool.sh
index b1ba0d9a088..7b957022f1a 100755
--- a/t/t7610-mergetool.sh
+++ b/t/t7610-mergetool.sh
@@ -33,7 +33,7 @@ test_expect_success 'setup' '
git add foo &&
git commit -m "Add foo"
) &&
- git submodule add /dev/null submod &&
+ git submodule add file:///dev/null submod &&
git add file1 "spaced name" file1[1-4] subdir/file3 .gitmodules submod &&
git commit -m "add initial versions" &&
@@ -614,7 +614,7 @@ test_expect_success 'submodule in subdirectory' '
)
) &&
test_when_finished "rm -rf subdir/subdir_module" &&
- git submodule add /dev/null subdir/subdir_module &&
+ git submodule add file:///dev/null subdir/subdir_module &&
git add subdir/subdir_module &&
git commit -m "add submodule in subdirectory" &&
--
2.38.0.1473.g172bcc0511c
next prev parent reply other threads:[~2022-11-15 23:40 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-05 11:54 [PATCH] t7610: fix flaky timeout issue, don't clone from example.com Ævar Arnfjörð Bjarmason
2022-11-09 22:47 ` Taylor Blau
2022-11-09 23:55 ` Ævar Arnfjörð Bjarmason
2022-11-10 2:17 ` Taylor Blau
2022-11-15 19:42 ` Taylor Blau
2022-11-15 23:40 ` Ævar Arnfjörð Bjarmason [this message]
2022-11-16 1:07 ` [PATCH] t7610: use "file:///dev/null", not "/dev/null", fixes MinGW Taylor Blau
2022-11-17 10:08 ` Ævar Arnfjörð Bjarmason
2022-11-17 21:50 ` Taylor Blau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=patch-1.1-21a9cb49299-20221115T233516Z-avarab@gmail.com \
--to=avarab@gmail.com \
--cc=git@vger.kernel.org \
--cc=me@ttaylorr.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).