diff --git a/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs b/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs index dc226fa691..0c756b4b7c 100644 --- a/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs +++ b/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs @@ -704,7 +704,7 @@ public override IndexOutput CreateOutput(string name, IOContext context) { if (existing != null) { - ramdir.m_sizeInBytes.AddAndGet(-existing.GetSizeInBytes()); // LUCENENET: GetAndAdd in Lucene, but we are not using the value + ramdir.m_sizeInBytes.GetAndAdd(-existing.GetSizeInBytes()); existing.directory = null; } ramdir.m_fileMap[name] = file; @@ -1558,4 +1558,4 @@ protected FakeIOException(SerializationInfo info, StreamingContext context) } #endif } -} \ No newline at end of file +} diff --git a/src/Lucene.Net.Tests/Search/TestBooleanOr.cs b/src/Lucene.Net.Tests/Search/TestBooleanOr.cs index 74971e4288..243be1e397 100644 --- a/src/Lucene.Net.Tests/Search/TestBooleanOr.cs +++ b/src/Lucene.Net.Tests/Search/TestBooleanOr.cs @@ -205,7 +205,7 @@ public virtual void TestBooleanScorerMax() while (end.Value < docCount) { int inc = TestUtil.NextInt32(Random, 1, 1000); - end.AddAndGet(inc); + end.GetAndAdd(inc); scorer.Score(c, end); }