Fix default format setting, add tests

This commit is contained in:
Matt Nadareski
2025-04-14 12:10:09 -04:00
parent 371bfb45fe
commit 8c2f25afc4
19 changed files with 178 additions and 2 deletions

View File

@@ -141,6 +141,7 @@ namespace SabreTools.DatFiles.Formats
public CommaSeparatedValue(DatFile? datFile) : base(datFile)
{
_delim = ',';
Header.SetFieldValue<DatFormat>(DatHeader.DatFormatKey, DatFormat.CSV);
}
}
@@ -156,6 +157,7 @@ namespace SabreTools.DatFiles.Formats
public SemicolonSeparatedValue(DatFile? datFile) : base(datFile)
{
_delim = ';';
Header.SetFieldValue<DatFormat>(DatHeader.DatFormatKey, DatFormat.SSV);
}
}
@@ -171,6 +173,7 @@ namespace SabreTools.DatFiles.Formats
public TabSeparatedValue(DatFile? datFile) : base(datFile)
{
_delim = '\t';
Header.SetFieldValue<DatFormat>(DatHeader.DatFormatKey, DatFormat.TSV);
}
}
}