lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nightowl...@apache.org
Subject [25/50] [abbrv] lucenenet git commit: Lucene.Net.Tests.Core (Index.TestLongPostings + Search.TestMultiPhraseQuery): suppressed warnings due to unreachable execution paths. A boolean variable is being used as a switch to test one condition vs another, but
Date Wed, 25 Jan 2017 03:44:09 GMT
Lucene.Net.Tests.Core (Index.TestLongPostings + Search.TestMultiPhraseQuery): suppressed warnings
due to unreachable execution paths. A boolean variable is being used as a switch to test one
condition vs another, but the compiler complains because the boolean is hard-coded true.


Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/c0c42f9e
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/c0c42f9e
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/c0c42f9e

Branch: refs/heads/api-work
Commit: c0c42f9ed3d54bf2cc0037f59698d9f64f6902ae
Parents: 9c9cba2
Author: Shad Storhaug <shad@shadstorhaug.com>
Authored: Wed Jan 25 05:47:01 2017 +0700
Committer: Shad Storhaug <shad@shadstorhaug.com>
Committed: Wed Jan 25 09:34:47 2017 +0700

----------------------------------------------------------------------
 src/Lucene.Net.Tests/core/Index/TestLongPostings.cs      | 2 ++
 src/Lucene.Net.Tests/core/Search/TestMultiPhraseQuery.cs | 2 ++
 2 files changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/c0c42f9e/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs b/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
index 72ed0ae..b871d39 100644
--- a/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
@@ -403,7 +403,9 @@ namespace Lucene.Net.Index
             }
             else
             {
+#pragma warning disable 162
                 r = DirectoryReader.Open(dir);
+#pragma warning restore 162
             }
 
             /*

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/c0c42f9e/src/Lucene.Net.Tests/core/Search/TestMultiPhraseQuery.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Search/TestMultiPhraseQuery.cs b/src/Lucene.Net.Tests/core/Search/TestMultiPhraseQuery.cs
index 556a7fd..8b2f669 100644
--- a/src/Lucene.Net.Tests/core/Search/TestMultiPhraseQuery.cs
+++ b/src/Lucene.Net.Tests/core/Search/TestMultiPhraseQuery.cs
@@ -436,8 +436,10 @@ namespace Lucene.Net.Search
             }
             else
             {
+#pragma warning disable 162
                 mpq.Add(new Term[] { new Term("field", "a") }, 0);
                 mpq.Add(new Term[] { new Term("field", "b"), new Term("field", "c") }, 0);
+#pragma warning restore 162
             }
             TopDocs hits = s.Search(mpq, 2);
             Assert.AreEqual(2, hits.TotalHits);


Mime
View raw message