guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Golang check phase skipping some tests?


From: Simon Tournier
Subject: Re: Golang check phase skipping some tests?
Date: Wed, 17 Jan 2024 16:53:14 +0100

Hi,

CC:
    $ ./etc/teams.scm list-members go
    Katherine Cox-Buday <cox.katherine.e+guix@gmail.com>
    Sharlatan Hellseher <sharlatanus@gmail.com>


On Sun, 14 Jan 2024 at 22:12, Troy Figiel <troy@troyfigiel.com> wrote:

> --8<---------------cut here---------------start------------->8---
> (define* (check #:key tests? import-path #:allow-other-keys)
>   "Run the tests for the package named by IMPORT-PATH."
>   (when tests?
>     (invoke "go" "test" (string-append import-path "/...")))
>   #t)
> --8<---------------cut here---------------end--------------->8---
>
> For example, if the -v flag is added (which might be a better default?)
> to the check phase of go-github-stretchr-testify, it can be seen that
> only `TestImports' runs, none of the tests in assert, http, etc.
> However, the source code in these subdirectories is still recursively
> copied to out during the install phase.
>
> Is this desired behaviour? I assumed it isn't, because it looks like we
> are skipping a lot of tests during the check phase. However, I might
> also simply be overlooking something here as I am new to packaging
> Golang with Guix.

>From your description, it seems a good idea.  What do Go “experts“
think?

Cheers,
simon



reply via email to

[Prev in Thread] Current Thread [Next in Thread]