This is an automated email from the ASF dual-hosted git repository.
nightowl888 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/lucenenet.git
The following commit(s) were added to refs/heads/master by this push:
new ce244dd Lucene.Net.Tests.Index.TestAddIndexes: Updated
NullReferenceException error checking to use IsNullPointerException() instead
(which covers the expected ArgumentNullException case)
ce244dd is described below
commit ce244dd103b3e78386bf0a94734aa71b64b61cc2
Author: Shad Storhaug <[email protected]>
AuthorDate: Mon Sep 27 00:01:05 2021 +0700
Lucene.Net.Tests.Index.TestAddIndexes: Updated NullReferenceException error
checking to use IsNullPointerException() instead (which covers the expected
ArgumentNullException case)
---
src/Lucene.Net.Tests/Index/TestAddIndexes.cs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/Lucene.Net.Tests/Index/TestAddIndexes.cs
b/src/Lucene.Net.Tests/Index/TestAddIndexes.cs
index 2c4f345..526d1b9 100644
--- a/src/Lucene.Net.Tests/Index/TestAddIndexes.cs
+++ b/src/Lucene.Net.Tests/Index/TestAddIndexes.cs
@@ -853,7 +853,7 @@ namespace Lucene.Net.Index
internal override void Handle(Exception t)
{
- if (!t.IsAlreadyClosedException() && !(t is
NullReferenceException))
+ if (!t.IsAlreadyClosedException() &&
!t.IsNullPointerException())
{
t.printStackTrace(Console.Out);
lock (failures)
@@ -942,7 +942,7 @@ namespace Lucene.Net.Index
{
bool report = true;
- if (t.IsAlreadyClosedException() || t is
MergePolicy.MergeAbortedException || t is NullReferenceException)
+ if (t.IsAlreadyClosedException() || t is
MergePolicy.MergeAbortedException || t.IsNullPointerException())
{
report = !didClose;
}