From nobody Tue Feb 20 22:05:03 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4TfYNw3B7rz59k6v; Tue, 20 Feb 2024 22:05:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4TfYNw1KLdz4sJg; Tue, 20 Feb 2024 22:05:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1708466704; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=B0QIs4Dl97ZTBrjbDCheGSNq5BrjeHg8AxGDWGrcWnU=; b=b+b+CA1c24+bJ25+FUhb2SizmVEaZf2Pw8czyOJ8gsrGfeVrYy3XWuf0LoLnNMFfcx3bTR jg6jnVHwRHKvKwmkPQ2L4WtoB8QmNjHL1507ZnFL23lreRVmhl9ecPJYUfJRv4d4D+YoiX ZRpzKvu0T7dEDZ1FvgMx4fRCwj9CT+NKL1TZAsjQDjaIeBnV2Dv9pI4QzxbnTmVEJ7R3Ks tc41vvhmZnaBkooVW+uj0oTInWLVKueV/g0wQK7h9GTnSBLjHG/bBiTqwdgdJV95sRGxDe GYmazdblcdzjeBSiBzJR2R7MYDNNauXC+6n95jlh4S7V8wJIRcDR0DjnLPeCqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1708466704; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=B0QIs4Dl97ZTBrjbDCheGSNq5BrjeHg8AxGDWGrcWnU=; b=pMFBS8GjGlv3/UBoHVb2GuK3hOWJ/Rh4V2MQ9ZjyMGLKKDmcFIoyMRUacBX6IrE81NODqm cTZ8eXl++l3JkiHbh4XDXJW2SJKpmGwuvcEGk89vta1cNnG20nELXPJFez1DV3iQd+vmxN jwFVfjFcB4BT6yi3db/hqTHcMJdNzc43jbHijG2bnrOg8YliLOn0Cr33/nf52shFERvm2y zIF2lblf9f5nIWeF+QpnFdVbI7gEJcF/R4l2s6ur0qwh3JcQ0y3yabjpefHuo5kupo4Qv/ jg3FwmUaqs0W5fLlYNvk+vlKQS3kbic7Y5WDDuig4OgF0KI97VvVEifzks9jgA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1708466704; a=rsa-sha256; cv=none; b=V/5MKK6/eNZ98y7f6Zndxtzn8yR/MR06FJMeSt12IhYJRZwk9byMLfx87LT8wxCS9eaBdI 9gQG8FdJTgiQmCIyvLKI0K/qAKMibINB/qnVcdJscWd1rb068BnPMIkSYRKzDvSnQoBh1C bgZHaHHaoQ+m/8r0XfP9a0uMvxGLpSVP+83D3AaVGbERQV2S8P7tT1YU2E3VQXsKO7slQ3 Xs7nonDjDT5KvbF9B0pkvKUYnBDlUauwVHeVC3MR6na0O4G7AmL+fTH5hDna3h1RCJoKwQ QFIvDf0RzhKL9te6FCxL8KBy1PWRGD4TYZks3q85Z/Dp72NYGeY0cqZCq7PJLA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4TfYNw0JJVzcR1; Tue, 20 Feb 2024 22:05:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 41KM53Hg063680; Tue, 20 Feb 2024 22:05:03 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 41KM53If063677; Tue, 20 Feb 2024 22:05:03 GMT (envelope-from git) Date: Tue, 20 Feb 2024 22:05:03 GMT Message-Id: <202402202205.41KM53If063677@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: e7308a60a5b7 - main - md5: Add test case for GNU input modes. List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e7308a60a5b77a1e4aff6e27eddef40fedabb98c Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=e7308a60a5b77a1e4aff6e27eddef40fedabb98c commit e7308a60a5b77a1e4aff6e27eddef40fedabb98c Author: Dag-Erling Smørgrav AuthorDate: 2024-02-20 22:04:32 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2024-02-20 22:04:32 +0000 md5: Add test case for GNU input modes. MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: allanjude, markj Differential Revision: https://reviews.freebsd.org/D43988 --- sbin/md5/tests/md5_test.sh | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/sbin/md5/tests/md5_test.sh b/sbin/md5/tests/md5_test.sh index 5b018b18c220..34bdf43f13ea 100644 --- a/sbin/md5/tests/md5_test.sh +++ b/sbin/md5/tests/md5_test.sh @@ -369,6 +369,28 @@ gnu_cflag_body() } +atf_test_case gnu_cflag_mode +gnu_cflag_mode_head() +{ + atf_set descr "Verify handling of input modes in GNU check mode" + atf_set require.progs "sha1sum" +} +gnu_cflag_mode_body() +{ + printf "The Magic Words are 01010011 01001111\r\n" >input + # The first line is malformed per GNU coreutils but matches + # what we produce when mode == mode_bsd && output_mode == + # output_reverse (i.e. `sha1 -r`) so we want to support it. + cat >digests <