From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id iNbVIPIqqGUTrwAAe85BDQ:P1 (envelope-from ) for ; Wed, 17 Jan 2024 20:30:58 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id iNbVIPIqqGUTrwAAe85BDQ (envelope-from ) for ; Wed, 17 Jan 2024 20:30:58 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=WBD3wMpE; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1705519858; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=DhBlQBGviToumJf/ufVDYpPPq50rLpHs85K+clDfjpg=; b=bRXYHH5Ou3FC1Hhy85P3I1luMrPWeEnTlHP2+cu727u0OaBJMgQY0AyVVNJb41HpR6pZOh HQroaqqWM43ztVuejjcqmgxpjL4L7sTsTJ1GRwWvyTUwHgZNjpoOeE1BSElY2p+xZKRPSZ iI/djtbX8H0zeNkFkTGHm+C6AteVDUIVp2cd7CS/eqn4jRukd2/LNHhz5QNIqBbxeI/npD Q20PKN0QqDDuLOpU9oisH6yr8aDZnnlvR8+ZttyfxxVdH3cC5JAnEoS0CRSbJk/IC62W7d Bv/JyqTg+MZxAa1XLsw/YzP5akbCBy5MRMVvtD7OPyz4nE7NthS+DN6uoTsGzA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=WBD3wMpE; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1705519858; a=rsa-sha256; cv=none; b=qakngIsyU4JbXkyilsfl1k5M1dC99BKw59cs+KGOp9Zp4loziwrT7hnxIPi613tW1YIGx9 m96G+B23LzGktmG0lAwXHtN7PgzxycMcZFSMltWcRGwtu+SbaaS7LUqxQfFcWyqaSlTasm BFQx4AiNLVBnjNNmd2lpL3DjbjQ/4ydrFDXmMTnj1HskQujRKSVgCnnFfsBmAjtPPwqK79 ZuwWRoxQjlM5ZcwIZQVsrbpVpNF4ompjQEQMbPVJpcVftT4GX5O0uIRyBcExfPSIUSLAt/ VcO5fJhsZZK1v6MW4i2FBS/hnqcBh12J2O9ZcA1RHW3yfcYjm9Ieeo0OcsR6mA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 6F8A367145 for ; Wed, 17 Jan 2024 20:30:58 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rQBcO-0000UY-7X; Wed, 17 Jan 2024 14:30:32 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rQBcH-0000Pk-2M for guix-devel@gnu.org; Wed, 17 Jan 2024 14:30:29 -0500 Received: from mail-yb1-xb30.google.com ([2607:f8b0:4864:20::b30]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rQBcE-0002dJ-Tj for guix-devel@gnu.org; Wed, 17 Jan 2024 14:30:24 -0500 Received: by mail-yb1-xb30.google.com with SMTP id 3f1490d57ef6-dc21d7a7042so2753534276.2 for ; Wed, 17 Jan 2024 11:30:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1705519821; x=1706124621; darn=gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=DhBlQBGviToumJf/ufVDYpPPq50rLpHs85K+clDfjpg=; b=WBD3wMpEO5ll5hQxjIL0SHoNk+orCnNN/oZBLJ6xsmX9xCyubW6DeZ0w1DsfeMgECi OIMZE98VjfqEPfqLBJNm788bU0uDcy/T3WkNUwHUvVesQceAJekweBhb2S/9zPRHMH52 kXMuwwiymb7YpqcfwCbipoK9EttEaCSFLAmNgy4sps6WfNj4Ny1A2agPewfT6nfo5LUB 8fGEEBzp8gx/4jisRPXnf2EQB0dGdD+ouwNQaBAqaDsxM54a28vMH8JzKgaXcViN9VOq GjR2/AvJWqZTttZIc+s1soHJk3eT6Wo0+0hMiWlaR8IjNa1U/GioVgGNpxtoFlxE+9wN C3vQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705519821; x=1706124621; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=DhBlQBGviToumJf/ufVDYpPPq50rLpHs85K+clDfjpg=; b=OqRlpowAUGosQe+4tgoemOv+uwVPPn5fKFXJPFnRIMAX1GKz6I3zM8jYtQESnzBcN6 WWlLTgbXedSseW0c2oFWL9MEbNVbI64XVr6Ddv7ZaaTrqVO+IPaKLlLzN2P9D3QNuvVZ fLqk3yXn8CAArnF+zEaTEqhxRL38PBP0EQWbgY8Toq3DSUQ1fStexc3/12dC+1oT7I0Q spMCrGzKd/jlJCML3gkjLBB90d9Q4/MsmFhvhp16y26WilJxcaNLGrAWgoxbvZPI61h9 gQHqopHLiHkBYw5hIwLSC6mB5J2kI/KqtkYxAWHJL9DUEnnBA0R5o0xSIuh0HaZF+c76 UrNQ== X-Gm-Message-State: AOJu0YykpYeISS+BG4iP4pDkIM5BqAk8zx2ljBkZjIf2Au9VU7nHCSqr ZepWMIdT9I/Cr0mGkcEpOLrP6+5l0wM= X-Google-Smtp-Source: AGHT+IGKmVGbfxRI8Ld5DxCbXs2S/mdXUDdfbaDS6JwsgigfbWgPGBgZZLsDPSjy5A7T+3n2Tnz3NA== X-Received: by 2002:a05:6902:50:b0:dbd:2b6:6cfd with SMTP id m16-20020a056902005000b00dbd02b66cfdmr4924337ybh.2.1705519820631; Wed, 17 Jan 2024 11:30:20 -0800 (PST) Received: from hurd (dsl-10-141-147.b2b2c.ca. [72.10.141.147]) by smtp.gmail.com with ESMTPSA id k15-20020a05621414ef00b0067f339c0c16sm5269280qvw.134.2024.01.17.11.30.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Jan 2024 11:30:20 -0800 (PST) From: Maxim Cournoyer To: Troy Figiel Cc: guix-devel@gnu.org Subject: Re: Golang check phase skipping some tests? In-Reply-To: (Tomas Volf's message of "Tue, 16 Jan 2024 12:16:08 +0100") References: <65b75d58-e27b-4d02-80be-d87b86bf0342@troyfigiel.com> Date: Wed, 17 Jan 2024 14:30:19 -0500 Message-ID: <87o7djn4fo.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::b30; envelope-from=maxim.cournoyer@gmail.com; helo=mail-yb1-xb30.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: guix-devel-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -9.00 X-Spam-Score: -9.00 X-Migadu-Queue-Id: 6F8A367145 X-Migadu-Scanner: mx12.migadu.com X-TUID: agRxA/msxWLM Hi Tomas, Tomas Volf <~@wolfsden.cz> writes: > On 2024-01-14 22:12:38 +0100, Troy Figiel wrote: >> Hi everyone, >> >> When looking into the Go build system, I noticed the default check phase >> runs (invoke "go" "test" import-path), which only runs the tests in the >> root directory of the source. Running the tests in all subdirectories >> would require something like this instead: >> >> --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. > > I tend to agree (on both accounts). I am not aware of anything Guix specific > here that would prevent it, but maybe someone from golang team will chime in. I'm not much of a Go person, but your suggestions sound reasonable. They'd have to be tested on the go-team branch to see whether it breaks many things (it probably would, since many more tests would be run). -- Thanks, Maxim