lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nightowl...@apache.org
Subject [3/4] lucenenet git commit: BUG: Lucene.Net.Benchmark.ByTask.Tasks.TestPerfTasksLogic.TestLocale(): Test was using no-NO which is not consistently supported across platforms on .NET. Changed the test (and the documentation) to use nb-NO instead.
Date Mon, 11 Sep 2017 14:34:58 GMT
BUG: Lucene.Net.Benchmark.ByTask.Tasks.TestPerfTasksLogic.TestLocale(): Test was using no-NO
which is not consistently supported across platforms on .NET. Changed the test (and the documentation)
to use nb-NO instead.


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

Branch: refs/heads/master
Commit: cb3215ab470f87c205d927f761e32474f5aca06e
Parents: f6475cb
Author: Shad Storhaug <shad@shadstorhaug.com>
Authored: Mon Sep 11 21:04:32 2017 +0700
Committer: Shad Storhaug <shad@shadstorhaug.com>
Committed: Mon Sep 11 21:04:32 2017 +0700

----------------------------------------------------------------------
 src/Lucene.Net.Benchmark/ByTask/Tasks/NewLocaleTask.cs      | 2 +-
 src/Lucene.Net.Tests.Benchmark/ByTask/TestPerfTasksLogic.cs | 9 +++++++--
 2 files changed, 8 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/cb3215ab/src/Lucene.Net.Benchmark/ByTask/Tasks/NewLocaleTask.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Benchmark/ByTask/Tasks/NewLocaleTask.cs b/src/Lucene.Net.Benchmark/ByTask/Tasks/NewLocaleTask.cs
index 135d203..a961207 100644
--- a/src/Lucene.Net.Benchmark/ByTask/Tasks/NewLocaleTask.cs
+++ b/src/Lucene.Net.Benchmark/ByTask/Tasks/NewLocaleTask.cs
@@ -29,7 +29,7 @@ namespace Lucene.Net.Benchmarks.ByTask.Tasks
     /// <list type="bullet">
     ///     <item><description><c>de</c>: Language "de"</description></item>
     ///     <item><description><code>en,US</code>: Language "en",
country "US"</description></item>
-    ///     <item><description><code>no-NO</code>: Language "no",
country "NO"</description></item>
+    ///     <item><description><code>nb-NO</code>: Language "nb"
(Bokmål), country "NO"</description></item>
     ///     <item><description><code>ROOT</code>: The <see cref="CultureInfo.InvariantCulture"/></description></item>
     /// </list>
     /// </remarks>

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/cb3215ab/src/Lucene.Net.Tests.Benchmark/ByTask/TestPerfTasksLogic.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests.Benchmark/ByTask/TestPerfTasksLogic.cs b/src/Lucene.Net.Tests.Benchmark/ByTask/TestPerfTasksLogic.cs
index 61e7bf1..8448fc8 100644
--- a/src/Lucene.Net.Tests.Benchmark/ByTask/TestPerfTasksLogic.cs
+++ b/src/Lucene.Net.Tests.Benchmark/ByTask/TestPerfTasksLogic.cs
@@ -975,8 +975,13 @@ namespace Lucene.Net.Benchmarks.ByTask
             assertEquals(new CultureInfo("en-US"), benchmark.RunData.Locale);
 
             // specify language + country + variant
-            benchmark = execBenchmark(getLocaleConfig("no,NO,NY"));
-            assertEquals(new CultureInfo("no-NO"/*, "NY"*/), benchmark.RunData.Locale);
+            //benchmark = execBenchmark(getLocaleConfig("no,NO,NY"));
+            //assertEquals(new CultureInfo("no-NO"/*, "NY"*/), benchmark.RunData.Locale);
+            // LUCENENET specific - in .NET Norwegian is specified as either nb-NO (Bokmål)
or 
+            // nn-NO (Nynorsk) + a few other dialects. no-NO works sometimes, but is not
+            // supported across all OS's, so doesn't make a reliable test case.
+            benchmark = execBenchmark(getLocaleConfig("nb,NO,NY"));
+            assertEquals(new CultureInfo("nb-NO"/*, "NY"*/), benchmark.RunData.Locale);
         }
 
         private String[] getLocaleConfig(String localeParam)


Mime
View raw message