Fix parsing MD2 and MD4 files; add test cases

This commit is contained in:
Matt Nadareski
2025-02-12 16:11:24 -05:00
parent ec2b56e973
commit dafd7db2a4
4 changed files with 6 additions and 2 deletions

View File

@@ -111,6 +111,8 @@ namespace SabreTools.Core.Tools
"csv" => true, "csv" => true,
"dat" => true, "dat" => true,
"json" => true, "json" => true,
"md2" => true,
"md4" => true,
"md5" => true, "md5" => true,
"sfv" => true, "sfv" => true,
"sha1" => true, "sha1" => true,

View File

@@ -29,8 +29,8 @@ namespace SabreTools.Test.DatTools
[InlineData("test-smdb.txt", DatFormat.EverdriveSMDB, 1)] [InlineData("test-smdb.txt", DatFormat.EverdriveSMDB, 1)]
//[InlineData(null, DatFormat.SabreJSON, 0)] // TODO: Create good-enough test file for this //[InlineData(null, DatFormat.SabreJSON, 0)] // TODO: Create good-enough test file for this
[InlineData("test-sfv.sfv", DatFormat.RedumpSFV, 1)] [InlineData("test-sfv.sfv", DatFormat.RedumpSFV, 1)]
//[InlineData("test-md2.md2", DatFormat.RedumpMD2, 1)] // TODO: Create good-enough test file for this [InlineData("test-md2.md2", DatFormat.RedumpMD2, 1)]
//[InlineData("test-md4.md4", DatFormat.RedumpMD4, 1)] // TODO: Create good-enough test file for this [InlineData("test-md4.md4", DatFormat.RedumpMD4, 1)]
[InlineData("test-md5.md5", DatFormat.RedumpMD5, 1)] [InlineData("test-md5.md5", DatFormat.RedumpMD5, 1)]
[InlineData("test-sha1.sha1", DatFormat.RedumpSHA1, 1)] [InlineData("test-sha1.sha1", DatFormat.RedumpSHA1, 1)]
[InlineData("test-sha256.sha256", DatFormat.RedumpSHA256, 1)] [InlineData("test-sha256.sha256", DatFormat.RedumpSHA256, 1)]

View File

@@ -0,0 +1 @@
8350e5a3e24c153df2275c9f80692773 rom.bin

View File

@@ -0,0 +1 @@
31d6cfe0d16ae931b73c59d7e0c089c0 rom.bin