lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From synhers...@apache.org
Subject [18/49] lucenenet git commit: TestFSTs: Added LongRunningTest and Ignore attributes for applicable tests.
Date Sun, 02 Oct 2016 10:16:49 GMT
TestFSTs: Added LongRunningTest and Ignore attributes for applicable tests.


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

Branch: refs/heads/master
Commit: 32e2105bba349544c3166d30f664ef7edd219a3a
Parents: d807eeb
Author: Shad Storhaug <shad@shadstorhaug.com>
Authored: Thu Sep 8 02:19:29 2016 +0700
Committer: Shad Storhaug <shad@shadstorhaug.com>
Committed: Thu Sep 8 06:41:01 2016 +0700

----------------------------------------------------------------------
 src/Lucene.Net.Tests/core/Util/Fst/TestFSTs.cs | 61 ++++++++++-----------
 1 file changed, 29 insertions(+), 32 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/32e2105b/src/Lucene.Net.Tests/core/Util/Fst/TestFSTs.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Util/Fst/TestFSTs.cs b/src/Lucene.Net.Tests/core/Util/Fst/TestFSTs.cs
index 3ff21be..8dde689 100644
--- a/src/Lucene.Net.Tests/core/Util/Fst/TestFSTs.cs
+++ b/src/Lucene.Net.Tests/core/Util/Fst/TestFSTs.cs
@@ -1,10 +1,14 @@
+using Lucene.Net.Attributes;
+using Lucene.Net.Randomized.Generators;
+using Lucene.Net.Support;
+using NUnit.Framework;
 using System;
-using System.Diagnostics;
 using System.Collections.Generic;
+using System.Diagnostics;
+using System.Globalization;
 using System.IO;
 using System.Linq;
 using System.Text;
-using Lucene.Net.Randomized.Generators;
 
 namespace Lucene.Net.Util.Fst
 {
@@ -25,46 +29,38 @@ namespace Lucene.Net.Util.Fst
      * limitations under the License.
      */
 
-    using MockAnalyzer = Lucene.Net.Analysis.MockAnalyzer;
+    //using Slow = Lucene.Net.Util.LuceneTestCase.Slow;
+    using Automaton = Lucene.Net.Util.Automaton.Automaton;
+    //using InputOutput = Lucene.Net.Util.Fst.BytesRefFSTEnum.InputOutput;
+    //using Arc = Lucene.Net.Util.Fst.FST.Arc;
+    using BytesReader = Lucene.Net.Util.Fst.FST.BytesReader;
+    using CompiledAutomaton = Lucene.Net.Util.Automaton.CompiledAutomaton;
+    using Directory = Lucene.Net.Store.Directory;
+    using DirectoryReader = Lucene.Net.Index.DirectoryReader;
     using Document = Lucene.Net.Documents.Document;
     using Field = Lucene.Net.Documents.Field;
-    using DirectoryReader = Lucene.Net.Index.DirectoryReader;
+    using FSDirectory = Lucene.Net.Store.FSDirectory;
+    using IndexInput = Lucene.Net.Store.IndexInput;
+    using IndexOutput = Lucene.Net.Store.IndexOutput;
     using IndexReader = Lucene.Net.Index.IndexReader;
+    using IndexSearcher = Lucene.Net.Search.IndexSearcher;
     using IndexWriter = Lucene.Net.Index.IndexWriter;
     using IndexWriterConfig = Lucene.Net.Index.IndexWriterConfig;
-    using MultiFields = Lucene.Net.Index.MultiFields;
-    using RandomIndexWriter = Lucene.Net.Index.RandomIndexWriter;
-    using Term = Lucene.Net.Index.Term;
-    using Terms = Lucene.Net.Index.Terms;
-    using TermsEnum = Lucene.Net.Index.TermsEnum;
-    using IndexSearcher = Lucene.Net.Search.IndexSearcher;
-    using TermQuery = Lucene.Net.Search.TermQuery;
-    using Directory = Lucene.Net.Store.Directory;
-    using FSDirectory = Lucene.Net.Store.FSDirectory;
     using IOContext = Lucene.Net.Store.IOContext;
-    using IndexInput = Lucene.Net.Store.IndexInput;
-    using IndexOutput = Lucene.Net.Store.IndexOutput;
+    using MockAnalyzer = Lucene.Net.Analysis.MockAnalyzer;
     using MockDirectoryWrapper = Lucene.Net.Store.MockDirectoryWrapper;
-    //using Slow = Lucene.Net.Util.LuceneTestCase.Slow;
-    using SuppressCodecs = Lucene.Net.Util.LuceneTestCase.SuppressCodecs;
-    using Automaton = Lucene.Net.Util.Automaton.Automaton;
-    using CompiledAutomaton = Lucene.Net.Util.Automaton.CompiledAutomaton;
-    using RegExp = Lucene.Net.Util.Automaton.RegExp;
-    //using InputOutput = Lucene.Net.Util.Fst.BytesRefFSTEnum.InputOutput;
-    //using Arc = Lucene.Net.Util.Fst.FST.Arc;
-    using BytesReader = Lucene.Net.Util.Fst.FST.BytesReader;
-    using Pair = Lucene.Net.Util.Fst.PairOutputs<long?, long?>.Pair;
+    using MultiFields = Lucene.Net.Index.MultiFields;
     //using ResultLong = Lucene.Net.Util.Fst.Util.Result<long?>;
     //using ResultPair = Lucene.Net.Util.Fst.Util.Result<long?>;
     using PackedInts = Lucene.Net.Util.Packed.PackedInts;
-    using Lucene.Net.Support;
-    using NUnit.Framework;
-    using System.Globalization;
+    using Pair = Lucene.Net.Util.Fst.PairOutputs<long?, long?>.Pair;
+    using RandomIndexWriter = Lucene.Net.Index.RandomIndexWriter;
+    using RegExp = Lucene.Net.Util.Automaton.RegExp;
+    using Term = Lucene.Net.Index.Term;
+    using TermQuery = Lucene.Net.Search.TermQuery;
+    using Terms = Lucene.Net.Index.Terms;
+    using TermsEnum = Lucene.Net.Index.TermsEnum;
 
-    /*
-    import static Lucene.Net.Util.Fst.FSTTester.GetRandomString;
-    import static Lucene.Net.Util.Fst.FSTTester.SimpleRandomString;
-    import static Lucene.Net.Util.Fst.FSTTester.ToIntsRef;*/
 
     [TestFixture]
     public class TestFSTs : LuceneTestCase
@@ -269,7 +265,7 @@ namespace Lucene.Net.Util.Fst
         }
 
 
-        [Test]
+        [Test, LongRunningTest, Timeout(27000000)] // 45 minutes to be on the safe side
         public virtual void TestRandomWords()
         {
             TestRandomWords(1000, AtLeast(2));
@@ -313,6 +309,7 @@ namespace Lucene.Net.Util.Fst
         }
 
         [Test]
+        [Ignore("LUCENENET TODO: This test will take around 10-14 hours to finish. It was
marked with a Nightly attribute in the original Java source, but we don't currently have a
corresponding attribute")]
         public virtual void TestBigSet()
         {
             TestRandomWords(TestUtil.NextInt(Random(), 50000, 60000), 1);


Mime
View raw message