git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Fix for failing tests on Solaris
@ 2022-04-29  6:23 Vladimir Marek
  2022-04-29 16:09 ` Carlo Marcelo Arenas Belón
  0 siblings, 1 reply; 3+ messages in thread
From: Vladimir Marek @ 2022-04-29  6:23 UTC (permalink / raw)
  To: git

Hello,

Sorry if this is not the best way to report issues.

Solaris ships git[1]. We run it's test suite and we were having multiple
failures[2]. I noticed that the tests do expect binaries to be found
in [3]:

SANE_TOOL_PATH = /usr/xpg6/bin:/usr/xpg4/bin

That paths contain posix conformant binaries, but the tests do expect
Linux-like behaving binaries.

The patch I am about to apply to git

--- git-2.35.1/config.mak.uname
+++ git-2.35.1/config.mak.uname
@@ -162,7 +162,7 @@ ifeq ($(uname_S),SunOS)
        NEEDS_SOCKET = YesPlease
        NEEDS_NSL = YesPlease
        SHELL_PATH = /bin/bash
-       SANE_TOOL_PATH = /usr/xpg6/bin:/usr/xpg4/bin
+       SANE_TOOL_PATH = /usr/gnu/bin
        HAVE_ALLOCA_H = YesPlease
        NO_STRCASESTR = YesPlease
        NO_MEMMEM = YesPlease

Makes all tests but t7812 pass successfully. t7812 fails on locales and
utf-8 which do behave differently in Solaris.

I would suggest to update the tests to use /usr/gnu/bin path.

[1] https://github.com/oracle/solaris-userland/tree/master/components/git
[2] https://github.com/oracle/solaris-userland/tree/master/components/git/test
[3] https://github.com/git/git/blob/master/config.mak.uname#L176

Thank you
-- 
	Vlad

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Fix for failing tests on Solaris
  2022-04-29  6:23 Fix for failing tests on Solaris Vladimir Marek
@ 2022-04-29 16:09 ` Carlo Marcelo Arenas Belón
  2022-04-29 16:48   ` Junio C Hamano
  0 siblings, 1 reply; 3+ messages in thread
From: Carlo Marcelo Arenas Belón @ 2022-04-29 16:09 UTC (permalink / raw)
  To: Vladimir Marek; +Cc: git

On Fri, Apr 29, 2022 at 08:23:37AM +0200, Vladimir Marek wrote:
> 
> That paths contain posix conformant binaries, but the tests do expect
> Linux-like behaving binaries.

Expecting Linux-like behaviour is indeed not what the tests should be
doing, so correcting that might ALSO help other people that don't have
an alternative GNU implementation available IMHO

So detailing those failures and fixing them might be preferable (even if
likely more difficult)

> --- git-2.35.1/config.mak.uname
> +++ git-2.35.1/config.mak.uname
> @@ -162,7 +162,7 @@ ifeq ($(uname_S),SunOS)
>         NEEDS_SOCKET = YesPlease
>         NEEDS_NSL = YesPlease
>         SHELL_PATH = /bin/bash
> -       SANE_TOOL_PATH = /usr/xpg6/bin:/usr/xpg4/bin
> +       SANE_TOOL_PATH = /usr/gnu/bin

I haven't used Solaris for a while (since around OpenSolaris Indiana
development stopped), but wouldn't this break in Solaris 10 and older?

> Makes all tests but t7812 pass successfully. t7812 fails on locales and
> utf-8 which do behave differently in Solaris.

And additional fix for that (since you seem to have access to a fresh
Solaris 11.4 installation at least), would be forthcomming.

Wondering also if there is a way to plug one of those from Oracle Cloud
through a GitHub actions so we could prevent future issues by including
Solaris in our CI runs.

Carlo

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Fix for failing tests on Solaris
  2022-04-29 16:09 ` Carlo Marcelo Arenas Belón
@ 2022-04-29 16:48   ` Junio C Hamano
  0 siblings, 0 replies; 3+ messages in thread
From: Junio C Hamano @ 2022-04-29 16:48 UTC (permalink / raw)
  To: Carlo Marcelo Arenas Belón; +Cc: Vladimir Marek, git

Carlo Marcelo Arenas Belón <carenas@gmail.com> writes:

>> --- git-2.35.1/config.mak.uname
>> +++ git-2.35.1/config.mak.uname
>> @@ -162,7 +162,7 @@ ifeq ($(uname_S),SunOS)
>>         NEEDS_SOCKET = YesPlease
>>         NEEDS_NSL = YesPlease
>>         SHELL_PATH = /bin/bash
>> -       SANE_TOOL_PATH = /usr/xpg6/bin:/usr/xpg4/bin
>> +       SANE_TOOL_PATH = /usr/gnu/bin
>
> I haven't used Solaris for a while (since around OpenSolaris Indiana
> development stopped), but wouldn't this break in Solaris 10 and older?
>
>> Makes all tests but t7812 pass successfully. t7812 fails on locales and
>> utf-8 which do behave differently in Solaris.
>
> And additional fix for that (since you seem to have access to a fresh
> Solaris 11.4 installation at least), would be forthcomming.
>
> Wondering also if there is a way to plug one of those from Oracle Cloud
> through a GitHub actions so we could prevent future issues by including
> Solaris in our CI runs.

I do not think we want to take this patch until we know how exactly
the tests failing for Vladimir fail without GNUism, which we do not
want to rely on.  If a test by mistake used "sed -i -e '<script>'"
GNUism which /usr/xpg[46]/bin/sed does not support, for example, we
want to know about it, so that we can move away from such a use of
GNUism.

Thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-04-29 16:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-29  6:23 Fix for failing tests on Solaris Vladimir Marek
2022-04-29 16:09 ` Carlo Marcelo Arenas Belón
2022-04-29 16:48   ` Junio C Hamano

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).