diff --git a/tests/Mimante.Tests/ServiceTests.cs b/tests/Mimante.Tests/ServiceTests.cs index 59da765..5624734 100644 --- a/tests/Mimante.Tests/ServiceTests.cs +++ b/tests/Mimante.Tests/ServiceTests.cs @@ -502,9 +502,10 @@ public class CsvExportTests(DatabaseFixture fx) Assert.Equal(new byte[] { 0xEF, 0xBB, 0xBF }, bytes[..3]); var lines = Encoding.UTF8.GetString(bytes[3..]).Split("\r\n", StringSplitOptions.RemoveEmptyEntries); var header = lines[0].Split(';'); - Assert.Equal(17 + BidFeatures.Size + 28, header.Length); + Assert.Equal(17 + BidFeatures.Size + 32, header.Length); Assert.Equal("id_decisione", header[0]); - Assert.Equal("motivazione", header[^1]); + Assert.Equal("motivazione", header[^5]); + Assert.Equal(new[] { "ripetizioni", "ultimo_prezzo", "parere_modello", "nota_fuoco" }, header[^4..]); var row = lines[1].Split(';'); Assert.Equal(header.Length, row.Length); Assert.Equal("3,2", row[Array.IndexOf(header, "prezzo")]); @@ -514,6 +515,7 @@ public class CsvExportTests(DatabaseFixture fx) Assert.Equal("manuale", row[Array.IndexOf(header, "risposto_tipo")]); Assert.Equal("4", row[Array.IndexOf(header, "risposto_dopo_s")]); Assert.Equal("1407", row[Array.IndexOf(header, "puntate_residue")]); + Assert.Equal("1", row[Array.IndexOf(header, "ripetizioni")]); Assert.Contains(row[17..(17 + BidFeatures.Size)], v => v == "1"); Assert.True(File.Exists(Path.Combine(paths.Exports, model.Files[1]))); Assert.Contains("Righe trovate: 1", File.ReadAllText(Path.Combine(paths.Exports, model.Files[1])));