From: Derrick Stolee Date: Thu, 24 May 2018 16:28:14 GMT Subject: Re: [PATCH v2 03/12] commit-graph: test that 'verify' finds corruption Message-ID: <33480b33-1baf-e822-981e-c7d4b392aeac@gmail.com> In-Reply-To: <86wovwdemu.fsf@gmail.com> On 5/21/2018 2:53 PM, Jakub Narebski wrote: >> +corrupt_data() { >> + file=$1 >> + pos=$2 >> + data="${3:-\0}" >> + printf "$data" | dd of="$file" bs=1 seek="$pos" conv=notrunc >> +} > First, if we do this that way (and not by adding a test helper), the use > of this function should be, I think, protected using appropriate test > prerequisite. Not everyone has 'dd' tool installed, for example on > MS Windows. Windows does not, but it is also missing many things this test suite needs. 'dd' is included in the Git for Windows SDK. I rebased this series onto Git for Windows and the tests passed when run in an SDK shell. Thanks, -Stolee