Remove openentrystream checks

This commit is contained in:
Adam Hathcock
2026-11-13 11:39:14 +00:00
parent 4b82e1728e
commit e676a26f05
4 changed files with 0 additions and 20 deletions

View File

@@ -102,11 +102,7 @@ public class SevenZipDeflateSolidTests : TestBase
continue;
}
#if LEGACY_DOTNET
using var stream = await reader.OpenEntryStreamAsync(CancellationToken.None);
#else
await using var stream = await reader.OpenEntryStreamAsync(CancellationToken.None);
#endif
if (index == 0 && firstEntryMode == 1)
{
Assert.True(

View File

@@ -363,11 +363,7 @@ public class Zip64DescriptorSizeTests
);
Assert.True(await reader.MoveToNextEntryAsync(CancellationToken.None));
var first = reader.Entry;
#if LEGACY_DOTNET
using (var stream = await reader.OpenEntryStreamAsync(CancellationToken.None))
#else
await using (var stream = await reader.OpenEntryStreamAsync(CancellationToken.None))
#endif
{
await stream.CopyToAsync(Stream.Null, 81920, CancellationToken.None);
}
@@ -378,11 +374,7 @@ public class Zip64DescriptorSizeTests
}
Assert.Equal("second", reader.Entry.Key);
using var second = new MemoryStream();
#if LEGACY_DOTNET
using (var stream = await reader.OpenEntryStreamAsync(CancellationToken.None))
#else
await using (var stream = await reader.OpenEntryStreamAsync(CancellationToken.None))
#endif
{
await stream.CopyToAsync(second, 81920, CancellationToken.None);
}

View File

@@ -143,11 +143,7 @@ public class Zip64NonSeekableTests
continue;
}
Assert.Equal(entries[index].Name, reader.Entry.Key);
#if LEGACY_DOTNET
using var source = await reader.OpenEntryStreamAsync(CancellationToken.None);
#else
await using var source = await reader.OpenEntryStreamAsync(CancellationToken.None);
#endif
using var extracted = new MemoryStream();
await source.CopyToAsync(extracted, 81920, CancellationToken.None);
Assert.Equal(entries[index++].Content, extracted.ToArray());

View File

@@ -77,11 +77,7 @@ public class ZipBZip2CorruptionTests : TestBase
{
while (await reader.MoveToNextEntryAsync(CancellationToken.None))
{
#if LEGACY_DOTNET
using var entry = await reader.OpenEntryStreamAsync(CancellationToken.None);
#else
await using var entry = await reader.OpenEntryStreamAsync(CancellationToken.None);
#endif
if (!skipEntry)
{
await entry.CopyToAsync(Stream.Null, 81920, CancellationToken.None);