]> source.dussan.org Git - poi.git/commitdiff
Bug 62042: Adjust gradle build to properly set the locale
authorDominik Stadler <centic@apache.org>
Thu, 8 Feb 2018 19:34:22 +0000 (19:34 +0000)
committerDominik Stadler <centic@apache.org>
Thu, 8 Feb 2018 19:34:22 +0000 (19:34 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1823596 13f79535-47bb-0310-9956-ffa450edef68

build.gradle
src/testcases/org/apache/poi/ss/usermodel/BaseTestColumnShifting.java

index cf32c436f64dd5295b4d13f062d66f83b2419345..5811fe43bcac247f90406ea828d49f138a677af9 100644 (file)
@@ -101,11 +101,12 @@ subprojects {
                exclude '**/TestUnfixedBugs.class'
                exclude '**/TestOneFile.class'
 
-        systemProperties = System.properties
-    
         // set heap size for the test JVM(s)
         minHeapSize = "128m"
         maxHeapSize = "768m"
+
+        // Specifying the local via system properties did not work, so we set them this way
+        jvmArgs '-Duser.language=en -Duser.country=US'
   
         // show standard out and standard error of the test JVM(s) on the console
         //testLogging.showStandardStreams = true
@@ -114,15 +115,8 @@ subprojects {
         systemProperties['user.dir'] = workingDir
         
         systemProperties['POI.testdata.path'] = '../../test-data'
-        //systemProperties['user.language'] = 'en'
-        //systemProperties['user.country'] = 'US'
     }
 
-       test.beforeSuite { TestDescriptor suite ->
-          System.setProperty('user.language', 'en')
-          System.setProperty('user.country', 'US')
-       }
-
     jacoco {
         toolVersion = '0.7.9'
     }
index 6184d9405b37a5914eaf6abbd044cc52be1b9c65..0b7aef693eac85a53144472155b0c25c5ce42c6d 100644 (file)
@@ -26,7 +26,7 @@ import static org.junit.Assert.assertTrue;
 
 import org.apache.poi.ss.usermodel.helpers.ColumnShifter;
 
-public class BaseTestColumnShifting {
+public abstract class BaseTestColumnShifting {
     protected Workbook wb;
     protected Sheet sheet1;
     protected ColumnShifter columnShifter;