lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lai...@apache.org
Subject lucenenet git commit: add additional test
Date Sun, 24 May 2015 19:53:59 GMT
Repository: lucenenet
Updated Branches:
  refs/heads/failingtests d331774ce -> 8248490ef


add additional test


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

Branch: refs/heads/failingtests
Commit: 8248490efebf2d67e05edcad4d761c17cfcc5cbf
Parents: d331774
Author: Laimonas Simutis <laimis@gmail.com>
Authored: Sun May 24 15:53:49 2015 -0400
Committer: Laimonas Simutis <laimis@gmail.com>
Committed: Sun May 24 15:53:49 2015 -0400

----------------------------------------------------------------------
 src/Lucene.Net.Tests/core/Search/TestFuzzyQuery.cs | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/8248490e/src/Lucene.Net.Tests/core/Search/TestFuzzyQuery.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Search/TestFuzzyQuery.cs b/src/Lucene.Net.Tests/core/Search/TestFuzzyQuery.cs
index 62ff6d7..c64cc7a 100644
--- a/src/Lucene.Net.Tests/core/Search/TestFuzzyQuery.cs
+++ b/src/Lucene.Net.Tests/core/Search/TestFuzzyQuery.cs
@@ -241,15 +241,17 @@ namespace Lucene.Net.Search
         [Category("Focus")]
         public virtual void FloatOutputs()
         {
-            var minSimilarity = 0.0;
-
-            var scaleFactor = 1.0f / (1.0f - minSimilarity);
+            for (var i = 0; i < 20; i++)
+            {
+                var minSimilarity = 0.0;
 
-            float similarity = 1.0f - (float)1/(float)7;
-            var max = (similarity - minSimilarity)*scaleFactor;
+                var scaleFactor = 1.0f/(1.0f - minSimilarity);
 
-            Console.WriteLine(max.ToString("f20"));
+                float similarity = 1.0f - (float) 1/(float) 7;
+                var max = (similarity - minSimilarity)*scaleFactor;
 
+                Console.WriteLine(max.ToString("f20"));
+            }
         }
 
         /// <summary>


Mime
View raw message