From 628ff0cde1185dc4cdcff02d73c3049886da770e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lengyel=20J=C3=A1nos=20Zolt=C3=A1n?= Date: Mon, 18 Nov 2024 18:10:34 +0100 Subject: [PATCH 1/2] integration test fix --- .../Modules/{ => AdoNetTests}/Global.cs | 1 - .../TestMethodIntegrationAttribute.cs | 22 +++++++++---------- 2 files changed, 11 insertions(+), 12 deletions(-) rename Tests/EtLast.Tests.Integration.AdoNetTests/Modules/{ => AdoNetTests}/Global.cs (83%) diff --git a/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/Global.cs b/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/AdoNetTests/Global.cs similarity index 83% rename from Tests/EtLast.Tests.Integration.AdoNetTests/Modules/Global.cs rename to Tests/EtLast.Tests.Integration.AdoNetTests/Modules/AdoNetTests/Global.cs index 30f0a96e..972f1624 100644 --- a/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/Global.cs +++ b/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/AdoNetTests/Global.cs @@ -2,5 +2,4 @@ global using System.Collections.Generic; global using System.Data.Common; global using System.Linq; -global using FizzCode.LightWeight; global using Microsoft.VisualStudio.TestTools.UnitTesting; diff --git a/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/AdoNetTests/TestMethodIntegrationAttribute.cs b/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/AdoNetTests/TestMethodIntegrationAttribute.cs index 4558bf00..9b0e50e3 100644 --- a/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/AdoNetTests/TestMethodIntegrationAttribute.cs +++ b/Tests/EtLast.Tests.Integration.AdoNetTests/Modules/AdoNetTests/TestMethodIntegrationAttribute.cs @@ -1,13 +1,13 @@ -namespace FizzCode.EtLast.Tests.Integration.Modules.AdoNetTests; - -public class TestMethodIntegrationAttribute : TestMethodAttribute -{ - public override TestResult[] Execute(ITestMethod testMethod) +namespace FizzCode.EtLast.Tests.Integration.Modules.AdoNetTests; + +public class TestMethodIntegrationAttribute : TestMethodAttribute +{ + public override TestResult[] Execute(ITestMethod testMethod) { -#if INTEGRATION - return base.Execute(testMethod); -#else - return [new TestResult { Outcome = UnitTestOutcome.Inconclusive }]; -#endif - } +#if INTEGRATION + return base.Execute(testMethod); +#else + return [new TestResult { Outcome = UnitTestOutcome.Inconclusive }]; +#endif + } } \ No newline at end of file From 6254af30757d34a98da3354fb8b8bffa06cc46a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lengyel=20J=C3=A1nos=20Zolt=C3=A1n?= Date: Mon, 18 Nov 2024 18:43:31 +0100 Subject: [PATCH 2/2] SBT -> brotli 5 --- .../StructuredBinaryTable/StructuredBinaryTableReader.cs | 4 ++-- .../WriteToStructuredBinaryTableMutator.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/EtLast/Processes/StructuredBinaryTable/StructuredBinaryTableReader.cs b/EtLast/Processes/StructuredBinaryTable/StructuredBinaryTableReader.cs index d68c6a8b..2e95939d 100644 --- a/EtLast/Processes/StructuredBinaryTable/StructuredBinaryTableReader.cs +++ b/EtLast/Processes/StructuredBinaryTable/StructuredBinaryTableReader.cs @@ -67,7 +67,7 @@ protected override IEnumerable Produce() { using (var bufferMs = new MemoryStream(buffer)) { - using (var ds = new DeflateStream(bufferMs, CompressionMode.Decompress, leaveOpen: true)) + using (var ds = new BrotliStream(bufferMs, CompressionMode.Decompress, leaveOpen: true)) { ds.CopyTo(headerUncompressed); } @@ -103,7 +103,7 @@ protected override IEnumerable Produce() using (var ums = new MemoryStream()) { using (var bufferMs = new MemoryStream(buffer)) - using (var ds = new DeflateStream(bufferMs, CompressionMode.Decompress, leaveOpen: true)) + using (var ds = new BrotliStream(bufferMs, CompressionMode.Decompress, leaveOpen: true)) ds.CopyTo(ums); ums.Position = 0; diff --git a/EtLast/Processes/StructuredBinaryTable/WriteToStructuredBinaryTableMutator.cs b/EtLast/Processes/StructuredBinaryTable/WriteToStructuredBinaryTableMutator.cs index 3a909546..d8a87069 100644 --- a/EtLast/Processes/StructuredBinaryTable/WriteToStructuredBinaryTableMutator.cs +++ b/EtLast/Processes/StructuredBinaryTable/WriteToStructuredBinaryTableMutator.cs @@ -139,7 +139,7 @@ private void WriteBuffer() using (var targetMs = new MemoryStream()) { - using (var ds = new DeflateStream(targetMs, CompressionLevel.Fastest)) + using (var ds = new BrotliStream(targetMs, new BrotliCompressionOptions() { Quality = 5 })) { _sinkEntry.Buffer.Position = 0; _sinkEntry.Buffer.CopyTo(ds);