threads / discuss / 37945

TTY tests are unnecessarily suppressed under Mac OS

Subject: TTY tests are unnecessarily suppressed under Mac OS

## tl;dr

3 messages between Nov 12, 2014 and Nov 13, 2014.

replies: 2people: 2as markdown or json

Michael Blume· Nov 12, 2014, 22:25 UTC · lore
>From lib_terminal.sh:

# Reading from the pty master seems to get stuck _sometimes_ # on Mac OS X 10.5.0, using Perl 5.10.0 or 5.8.9. # # Reproduction recipe: run # # i=0 # while ./test-terminal.perl echo hi $i # do # : $((i = $i + 1)) # done # # After 2000 iterations or so it hangs. # https://rt.cpan.org/Ticket/Display.html?id=65692 # test "$(uname -s)" != Darwin &&

I tried the reproduction recipe on my mac and couldn't reproduce, so it may make sense to take this switch out? In any case, I've set my automated mac build to include TTY tests

Jeff King· Nov 13, 2014, 20:20 UTC · re: Michael Blume · lore

Re: TTY tests are unnecessarily suppressed under Mac OS

On Wed, Nov 12, 2014 at 02:25:52PM -0800, Michael Blume wrote:
Show 21 quoted lines
> From lib_terminal.sh:
> 
> # Reading from the pty master seems to get stuck _sometimes_
> # on Mac OS X 10.5.0, using Perl 5.10.0 or 5.8.9.
> #
> # Reproduction recipe: run
> #
> # i=0
> # while ./test-terminal.perl echo hi $i
> # do
> # : $((i = $i + 1))
> # done
> #
> # After 2000 iterations or so it hangs.
> # https://rt.cpan.org/Ticket/Display.html?id=65692
> #
> test "$(uname -s)" != Darwin &&
> 
> I tried the reproduction recipe on my mac and couldn't reproduce, so
> it may make sense to take this switch out? In any case, I've set my
> automated mac build to include TTY tests

10.5.0 is pretty ancient at this point; I can well believe that the upstream problem has been fixed. It would be nice if we knew in which version it was fixed, though. Just dropping the restriction risks people getting spurious failures if they are on an old enough version.

Do you want to roll a patch that checks $(uname) to see if we're on a recent-enough version (where we can just be conservative, and assume whatever version you have is the first one to fix it)?

-Peff
Jeff King· Nov 13, 2014, 21:10 UTC · lore

Re: TTY tests are unnecessarily suppressed under Mac OS

On Thu, Nov 13, 2014 at 09:06:51PM +0000, Michael Blume wrote:
> Can do =)
> 
> uname -r spits out "14.0.0". Is there anything in git's testing library for
> comparing version strings or should I roll my own?
No, there's nothing standard for comparing version numbers. Probably
    test "$(uname -r | cut -d. -f1") -ge 14
sufficient.
-Peff

← back to recent threads