Fix Nillable for fields and set the local for TCK to be independent from the platform running the suite

Signed-off-by: Jean-Louis Monteiro <jlmonteiro@tomitribe.com>
diff --git a/johnzon-jsonb/src/main/java/org/apache/johnzon/jsonb/JsonbAccessMode.java b/johnzon-jsonb/src/main/java/org/apache/johnzon/jsonb/JsonbAccessMode.java
index f6036c5..fb3f3fc 100644
--- a/johnzon-jsonb/src/main/java/org/apache/johnzon/jsonb/JsonbAccessMode.java
+++ b/johnzon-jsonb/src/main/java/org/apache/johnzon/jsonb/JsonbAccessMode.java
@@ -607,8 +607,9 @@
 
             final WriterConverters writerConverters = new WriterConverters(annotations, types);
             final JsonbProperty property = annotations.getAnnotation(JsonbProperty.class);
-            final JsonbNillable nillable = annotations.getClassOrPackageAnnotation(JsonbNillable.class);
-            final boolean isNillable = isNillable(property, nillable);
+            final JsonbNillable propertyNillable = annotations.getAnnotation(JsonbNillable.class);
+            final JsonbNillable classOrPackageNillable = annotations.getClassOrPackageAnnotation(JsonbNillable.class);
+            final boolean isNillable = isNillable(property, propertyNillable, classOrPackageNillable);
             final String key = property == null || property.value().isEmpty() ? naming.translateName(entry.getKey()) : property.value();
             if (result.put(key, new Reader() {
                 @Override
@@ -725,8 +726,9 @@
 
             final ReaderConverters converters = new ReaderConverters(initialWriter);
             final JsonbProperty property = initialWriter.getAnnotation(JsonbProperty.class);
-            final JsonbNillable nillable = initialWriter.getClassOrPackageAnnotation(JsonbNillable.class);
-            final boolean isNillable = isNillable(property, nillable);
+            final JsonbNillable propertyNillable = initialWriter.getAnnotation(JsonbNillable.class);
+            final JsonbNillable classOrPackageNillable = initialWriter.getClassOrPackageAnnotation(JsonbNillable.class);
+            final boolean isNillable = isNillable(property, propertyNillable, classOrPackageNillable);
             final String key = property == null || property.value().isEmpty() ? naming.translateName(entry.getKey()) : property.value();
             if (result.put(key, new Writer() {
                 @Override
@@ -829,12 +831,14 @@
                 });
     }
 
-    private boolean isNillable(final JsonbProperty property, final JsonbNillable nillable) {
-        if (property != null) {
+    private boolean isNillable(final JsonbProperty property, final JsonbNillable propertyNillable, final JsonbNillable classOrPackageNillable) {
+        if (propertyNillable != null) {
+            return propertyNillable.value();
+        } else if (property != null) {
             return property.nillable();
         }
-        if (nillable != null) {
-            return nillable.value();
+        if (classOrPackageNillable != null) {
+            return classOrPackageNillable.value();
         }
         return globalIsNillable;
     }
diff --git a/tck/jsonb/pom.xml b/tck/jsonb/pom.xml
index 5122523..8c83f21 100644
--- a/tck/jsonb/pom.xml
+++ b/tck/jsonb/pom.xml
@@ -138,6 +138,7 @@
           <systemProperties>
             <signature.sigTestClasspath>${project.build.outputDirectory}</signature.sigTestClasspath>
           </systemProperties>
+          <argLine>-Duser.language=en -Duser.region=US</argLine>
         </configuration>
       </plugin>
     </plugins>