easyfmxu / owasp-esapi-java

Automatically exported from code.google.com/p/owasp-esapi-java
Other
0 stars 0 forks source link

ValidatorTest.testIsValidDate fails if default locale is not US #310

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. export LANG=de_DE.UTF-8
2. mvn clean -Dtest=ValidatorTest#testIsValidDate test

What is the expected output? 
- the test should pass

What do you see instead?
- Failed tests:   testIsValidDate(org.owasp.esapi.reference.ValidatorTest)

Attached a patch to use SimpleDateFormat with Locale.US instead of using the 
environment default Locale.

Original issue reported on code.google.com by Dietrich.Frank@gmail.com on 6 Nov 2013 at 10:26

Attachments:

GoogleCodeExporter commented 9 years ago
Note that the goal for the test is NOT to make it work with the default locale, 
but rather just to hard-code it for the US locale.

Original comment by kevin.w.wall@gmail.com on 23 Sep 2014 at 1:58

GoogleCodeExporter commented 9 years ago

Original comment by kevin.w.wall@gmail.com on 27 Sep 2014 at 3:12