Files
libyal-libexe/synctestdata.ps1
T
2023-09-03 11:27:23 +02:00

24 lines
658 B
PowerShell

# Script that synchronizes the local test data
#
# Version: 20230709
$TestSet = "public"
$TestInputDirectory = "tests/input"
$TestFiles = "nowrc_test.dll wrc_test.dll"
If (-Not (Test-Path ${TestInputDirectory}))
{
New-Item -Name ${TestInputDirectory} -ItemType "directory" | Out-Null
}
If (-Not (Test-Path "${TestInputDirectory}\${TestSet}"))
{
New-Item -Name "${TestInputDirectory}\${TestSet}" -ItemType "directory" | Out-Null
}
ForEach ($TestFile in ${TestFiles} -split " ")
{
$Url = "https://github.com/libyal/testdata/blob/main/pe_coff/${TestFile}?raw=true"
Invoke-WebRequest -Uri ${Url} -OutFile "${TestInputDirectory}\${TestSet}\${TestFile}"
}