From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-1468050-garchives=archives.gentoo.org@lists.gentoo.org> Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id CFD43158020 for <garchives@archives.gentoo.org>; Fri, 16 Dec 2022 22:57:19 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id EA5DFE07FE; Fri, 16 Dec 2022 22:57:18 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (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) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 99BFCE07FE for <gentoo-commits@lists.gentoo.org>; Fri, 16 Dec 2022 22:57:18 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (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) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A84F73410A9 for <gentoo-commits@lists.gentoo.org>; Fri, 16 Dec 2022 22:57:17 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id E1A1D77D for <gentoo-commits@lists.gentoo.org>; Fri, 16 Dec 2022 22:57:15 +0000 (UTC) From: "Sam James" <sam@gentoo.org> To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" <sam@gentoo.org> Message-ID: <1671231430.aff32e17fff196cc91e9c90115b83035b0710512.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: app-forensics/volatility3/ X-VCS-Repository: repo/gentoo X-VCS-Files: app-forensics/volatility3/volatility3-2.4.0-r1.ebuild X-VCS-Directories: app-forensics/volatility3/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: aff32e17fff196cc91e9c90115b83035b0710512 X-VCS-Branch: master Date: Fri, 16 Dec 2022 22:57:15 +0000 (UTC) Precedence: bulk List-Post: <mailto:gentoo-commits@lists.gentoo.org> List-Help: <mailto:gentoo-commits+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org> X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 87e73ec2-cf91-4ffb-a95d-6a08b05db6fa X-Archives-Hash: cd6954723161f14afda1232e2869c1e6 commit: aff32e17fff196cc91e9c90115b83035b0710512 Author: Mario Haustein <mario.haustein <AT> hrz <DOT> tu-chemnitz <DOT> de> AuthorDate: Fri Dec 16 22:29:16 2022 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Fri Dec 16 22:57:10 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=aff32e17 app-forensics/volatility3: enable tests Signed-off-by: Mario Haustein <mario.haustein <AT> hrz.tu-chemnitz.de> Closes: https://github.com/gentoo/gentoo/pull/28684 Signed-off-by: Sam James <sam <AT> gentoo.org> .../volatility3/volatility3-2.4.0-r1.ebuild | 27 ++++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/app-forensics/volatility3/volatility3-2.4.0-r1.ebuild b/app-forensics/volatility3/volatility3-2.4.0-r1.ebuild index c167af282f11..042b1f014ec5 100644 --- a/app-forensics/volatility3/volatility3-2.4.0-r1.ebuild +++ b/app-forensics/volatility3/volatility3-2.4.0-r1.ebuild @@ -11,13 +11,20 @@ MY_PV=${PV//_beta/-beta.} DESCRIPTION="Framework for analyzing volatile memory" HOMEPAGE="https://github.com/volatilityfoundation/volatility3/ https://www.volatilityfoundation.org/" -SRC_URI="https://github.com/volatilityfoundation/volatility3/archive/v${MY_PV}.tar.gz -> ${P}.gh.tar.gz" +SRC_URI=" + https://github.com/volatilityfoundation/volatility3/archive/v${MY_PV}.tar.gz -> ${P}.gh.tar.gz + test? + ( + https://downloads.volatilityfoundation.org/volatility3/images/win-xp-laptop-2005-06-25.img.gz -> ${PN}-win-xp-laptop-2005-06-25.img.gz + https://downloads.volatilityfoundation.org/volatility3/images/linux-sample-1.bin.gz -> ${PN}-linux-sample-1.bin.gz + ) +" S="${WORKDIR}"/${PN}-${MY_PV} LICENSE="GPL-2+" SLOT="0" KEYWORDS="~amd64 ~x86" -IUSE="crypt disasm jsonschema leechcore snappy yara" +IUSE="crypt disasm jsonschema leechcore snappy test yara" RDEPEND=" >=dev-python/pefile-2017.8.1[${PYTHON_USEDEP}] @@ -33,3 +40,19 @@ DEPEND="${RDEPEND}" PATCHES=( "${FILESDIR}/${P}-dont-install-tests.patch" ) + +# Tests require optional features +REQUIRED_USE="test? ( yara )" + +RESTRICT="!test? ( test )" + +python_test() +{ + # see .github/workflows/test.yaml + "${EPYTHON}" "${S}/test/test_volatility.py" --volatility=vol.py \ + --image "${WORKDIR}/${PN}-win-xp-laptop-2005-06-25.img" -k test_windows -v || \ + die "Tests fail with ${EPYTHON}" + "${EPYTHON}" "${S}/test/test_volatility.py" --volatility=vol.py \ + --image "${WORKDIR}/${PN}-linux-sample-1.bin" -k test_linux -v || \ + die "Tests fail with ${EPYTHON}" +}