From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Taylan Kammer Newsgroups: gmane.lisp.guile.bugs Subject: bug#72383: srfi-64: test-runner-reset clobbers the run list Date: Wed, 2 Oct 2024 01:35:03 +0200 Message-ID: <4d857bf0-882a-4148-81ef-f130a0c9a9f4@gmail.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20150"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird To: Tomas Volf <~@wolfsden.cz>, 72383@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Wed Oct 02 01:37:26 2024 Return-path: Envelope-to: guile-bugs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1svmQn-00056N-EU for guile-bugs@m.gmane-mx.org; Wed, 02 Oct 2024 01:37:25 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1svmQb-00050G-Jo; Tue, 01 Oct 2024 19:37:13 -0400 Original-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 1svmQQ-0004xK-Rg for bug-guile@gnu.org; Tue, 01 Oct 2024 19:37:04 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1svmQQ-0002Ro-ID for bug-guile@gnu.org; Tue, 01 Oct 2024 19:37:02 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=In-Reply-To:From:References:MIME-Version:Date:To:Subject; bh=LZArJju99oHPHSixXPkp/vTkiK4OnC3aTli+ZpnbmEw=; b=axF5mi9wjV1TP03gfQ1He3adxMVVgPd9+AQdww5wZqZNrWSQ6BDguwzI5VRq3ppSdMDbuR3U8QnztL4GsvaGVKv5PaaJxhdYgt+edMLCbzxSgHcPzmZsjhX0088wDevI6bw3S57vqBcZD7Wqy6XM+bJfb0klFRIxWCNqQc17ulbQOajNpnQz5PeZ1ZJBZwG71Cmx7e5IE9qB2uFNA9/CkjemUANWgLYpsZW2jo5ejJtDcOHlMVLbrqe6d/t48hDIWjc0OjZKVU8pXyVFHIomIoyf/v3hM68RWnS/sLrFQcmrnPHvbfMoCpNB4w9Q7WPGXZ7Zp4ouzbXF5SLFyzc5nw==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1svmQQ-0000US-5g for bug-guile@gnu.org; Tue, 01 Oct 2024 19:37:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Taylan Kammer Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Tue, 01 Oct 2024 23:37:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72383 X-GNU-PR-Package: guile Original-Received: via spool by 72383-submit@debbugs.gnu.org id=B72383.17278257691847 (code B ref 72383); Tue, 01 Oct 2024 23:37:02 +0000 Original-Received: (at 72383) by debbugs.gnu.org; 1 Oct 2024 23:36:09 +0000 Original-Received: from localhost ([127.0.0.1]:54374 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1svmPY-0000Tj-RE for submit@debbugs.gnu.org; Tue, 01 Oct 2024 19:36:09 -0400 Original-Received: from mail-ed1-f48.google.com ([209.85.208.48]:38888) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1svmPW-0000Td-Vi for 72383@debbugs.gnu.org; Tue, 01 Oct 2024 19:36:07 -0400 Original-Received: by mail-ed1-f48.google.com with SMTP id 4fb4d7f45d1cf-5c876b6c061so601845a12.3 for <72383@debbugs.gnu.org>; Tue, 01 Oct 2024 16:36:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1727825706; x=1728430506; darn=debbugs.gnu.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id:from :to:cc:subject:date:message-id:reply-to; bh=LZArJju99oHPHSixXPkp/vTkiK4OnC3aTli+ZpnbmEw=; b=AnSzyhjM2QHIGcRPzAy5pxaOApZjFSBjoSkeWvHhh/71XvMXSm+TxH9Qo3BOctaqJM RTNkcoqyX6Q7Y/f/txY7axQ//VispxKgOWehfCDmHNksk35CQ/oJRUR8UvnXTwXcoAGV maiOOOHuSZBVU27p82QqzXLcqKDPFjdqdl1Z7HGti7cKK8nZ6oKdDGUb4Mc/82Wx1U/a 9PhEZ6LvGAszlu9TbmRSFY8IHqNHj6zQeKDJ7DLLl2rsxK5m/iIG9AjP3mrPih8f0nhP ucaD8Lunu5TFW4kTCdiUJE4bSgLeksHBvJI4ds5jYBADaT31NJGH7MJNrIjqX9B33fhA 64AQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1727825706; x=1728430506; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=LZArJju99oHPHSixXPkp/vTkiK4OnC3aTli+ZpnbmEw=; b=UQYrB14QzR4YeFknOQ9We7N9Vija7itNOK2rXEOLL27HL+kscMlXj+3fWyClHWDdQH nenhevfKt+dFpI3YalVS7WbFj+gzOBfij0xlx30Cgfd01eF4oCYuZYSFWKdFIjdrbQWm i8aDr8I/9YX89j91jWfbFI6Po2SqUixIK62uDZXPRHaW9psYo423vMtxq/Z7HjgxrdoW Yrhdv4afMtcjOuTJHmJIuAZDaK20yzCu7xyWZeXmZCQ4T2c3VAvHAO64ImiMf61M0KL8 UKydJ5kFqzpKsVZeyj2F9thNzeR48QOaUf72ZyhTrVfqizFrSZzFyYfSnN0dOIJofJEc 5ICw== X-Forwarded-Encrypted: i=1; AJvYcCUhusupqI7ori9YkNWpcz60TeBW6PTcq7KHTHlqEX+Du6xa6wHWVplP3+fcRUyDHyxcHTY+xw==@debbugs.gnu.org X-Gm-Message-State: AOJu0YxrWf9NNQTaJv1Krr0RJDmZ3HNWrTUuNLHq7W3zuo4arxNRDu5H RO61Zu50DhZeqjpe7Qs51emHXFIhoI1anncfq8SuI+6sXNw+39Ap X-Google-Smtp-Source: AGHT+IHE5VxJnROIAPuTw1/QqE5DCZAp9G0Hcm95jGNI2h1BoM2r39Y1CFV3JWhuXBW3JriF5OUQzg== X-Received: by 2002:a17:907:6d14:b0:a8d:2624:1a84 with SMTP id a640c23a62f3a-a98f8363879mr48457566b.11.1727825706176; Tue, 01 Oct 2024 16:35:06 -0700 (PDT) Original-Received: from ?IPV6:2003:106:8f04:c300:95ac:529d:6db3:196b? (p200301068f04c30095ac529d6db3196b.dip0.t-ipconnect.de. [2003:106:8f04:c300:95ac:529d:6db3:196b]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a93c299ac82sm774412466b.217.2024.10.01.16.35.04 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 01 Oct 2024 16:35:05 -0700 (PDT) Content-Language: en-US In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Original-Sender: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.lisp.guile.bugs:11015 Archived-At: On 30.07.2024 21:51, Tomas Volf wrote: > Hello, > > I think I found a bug in (srfi srfi-64) module shipped with GNU Guile. > > Test runner is specified as: > >> A test-runner is an object that runs a test-suite, and manages the state. The >> test group path, and the sets skip and expected-fail specifiers are part of >> the test-runner. A test-runner will also typically accumulate statistics about >> executed tests. > Based on this description, run list is *not* supposed to be part of the test > runner state, therefore test-runner-reset should not touch it. However that > does not seem to be the case: > > (use-modules (srfi srfi-64)) > (test-apply (test-match-name "t-a") > (λ () > (test-begin "x") > (test-assert "t-a" (pk 't-a)) > (test-assert "t-b" (pk 't-b)) > > (test-runner-reset (test-runner-current)) > > (test-begin "x") > (test-assert "t-a" (pk 't-a)) > (test-assert "t-b" (pk 't-b)))) > > Prints: > > %%%% Starting test x (Writing full log to "x.log") > > ;;; (t-a) > %%%% Starting test x (Writing full log to "x.log") > > ;;; (t-a) > > ;;; (t-b) > > Notice that in the second part, t-b is executed despite not supposed to be on > the run list. > > Have a nice day > Tomas Volf > > I agree. The run-list is an implementation detail that only exists for test-apply, isn't used anywhere else, isn't exposed to the user, and is never mentioned in the spec. It shouldn't be possible for the user to ever affect it directly. I've fixed this in my implementation of SRFI-64 as follows:     https://codeberg.org/taylan/scheme-srfis/commit/ec07393f809edd249748a884641fb2e63292da79 - Taylan