Revert "Support for custom boundaries implemented. v1 - will be reverted due to 5x slower performance."
This reverts commit 22d8593e1f.
This commit is contained in:
1 parent
22d8593e1f
commit
2ff1aab655
12 files changed
+92
-192
No files matched your search
@@ -338,13 +338,13 @@ namespace Recyclable.CollectionsTests
|
||||
|
||||
// Arrange
|
||||
using var list = new RecyclableList<object>(testData, itemsCount);
|
||||
_ = ((object[])list.AsArray)[..itemsCount].Should().AllSatisfy(x => x.Should().NotBeNull());
|
||||
_ = list.AsArray[..itemsCount].Should().AllSatisfy(x => x.Should().NotBeNull());
|
||||
|
||||
// Act
|
||||
list.Clear();
|
||||
|
||||
// Assert
|
||||
_ = ((object[])list.AsArray)[..itemsCount].Should().AllSatisfy(x => x.Should().BeNull());
|
||||
_ = list.AsArray[..itemsCount].Should().AllSatisfy(x => x.Should().BeNull());
|
||||
}
|
||||
|
||||
[Theory]
|
||||
@@ -393,12 +393,6 @@ namespace Recyclable.CollectionsTests
|
||||
_ = list.Should().Equal(testData);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ConstructorShouldCreateArrayWithCustomBoundaries()
|
||||
{
|
||||
using var list = new RecyclableList<long>(-10);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[MemberData(nameof(RecyclableLongListTestData.SourceDataVariants), MemberType = typeof(RecyclableLongListTestData))]
|
||||
public void ConstructorSourceShouldInitializeList(string testCase, IEnumerable<long> testData, int itemsCount)
|
||||
@@ -481,14 +475,14 @@ namespace Recyclable.CollectionsTests
|
||||
// Arrange
|
||||
using var list = new RecyclableList<object>(testData, itemsCount);
|
||||
var listArray = list.AsArray;
|
||||
_ = ((object[])list.AsArray)[..itemsCount].Should().NotBeNull();
|
||||
_ = ((object[])listArray)[..itemsCount].Should().AllSatisfy(x => x.Should().NotBeNull());
|
||||
_ = list.AsArray[..itemsCount].Should().NotBeNull();
|
||||
_ = listArray[..itemsCount].Should().AllSatisfy(x => x.Should().NotBeNull());
|
||||
|
||||
// Act
|
||||
list.Dispose();
|
||||
|
||||
// Assert
|
||||
_ = ((object[])listArray)[..itemsCount].Should().AllSatisfy(x => x.Should().BeNull());
|
||||
_ = listArray[..itemsCount].Should().AllSatisfy(x => x.Should().BeNull());
|
||||
}
|
||||
|
||||
[Fact]
|
||||
|
||||
Reference in new issue
Block a user