Don't assume "3 5" is unparseable in the current culture in DoubleTest.Parse()
authorNiklas Therning <niklas@therning.org>
Tue, 23 Aug 2016 09:32:41 +0000 (11:32 +0200)
committerNiklas Therning <niklas@therning.org>
Tue, 23 Aug 2016 10:20:28 +0000 (12:20 +0200)
DoubleTest.Parse() expects "3 5" to be unparseable in the current culture and
expects an exception to be thrown. In sv-SE however "3 5" parses to 35 and
this test fails.

This patch sets the current culture to en-US when the DoubleTest.Parse() test
is run.

mcs/class/corlib/Test/System/DoubleTest.cs

index 30fe1dce81793175172850c761f64df3b888b4b9..45d7ee110519c0c7a01f1d5e155b064f5f965eb0 100644 (file)
@@ -147,6 +147,7 @@ namespace MonoTests.System
                }
 
                [Test]
+               [Culture ("en-US")]
                public void Parse ()
                {
                        int i = 0;