mirror of
https://github.com/beefytech/Beef.git
synced 2025-07-04 23:36:00 +02:00
Method instead of mixin
This commit is contained in:
parent
1efdb334b4
commit
dc5701d473
1 changed files with 9 additions and 9 deletions
|
@ -4,7 +4,7 @@ namespace Tests
|
|||
{
|
||||
class Floats
|
||||
{
|
||||
public static mixin FloatParseTest(StringView string, float expectedResult)
|
||||
public static void FloatParseTest(StringView string, float expectedResult)
|
||||
{
|
||||
float result = float.Parse(string);
|
||||
Test.Assert(expectedResult == result);
|
||||
|
@ -13,14 +13,14 @@ namespace Tests
|
|||
[Test]
|
||||
public static void TestBasics()
|
||||
{
|
||||
FloatParseTest!("1.2", 1.2f);
|
||||
FloatParseTest!("-0.2", -0.2f);
|
||||
FloatParseTest!("2.5E2", 2.5E2f);
|
||||
FloatParseTest!("2.7E-10", 2.7E-10f);
|
||||
FloatParseTest!("-0.17E-7", -0.17E-7f);
|
||||
FloatParseTest!("8.7e6", 8.7e6f);
|
||||
FloatParseTest!("3.3e-11", 3.3e-11f);
|
||||
FloatParseTest!("0.002e5", 0.002e5f);
|
||||
FloatParseTest("1.2", 1.2f);
|
||||
FloatParseTest("-0.2", -0.2f);
|
||||
FloatParseTest("2.5E2", 2.5E2f);
|
||||
FloatParseTest("2.7E-10", 2.7E-10f);
|
||||
FloatParseTest("-0.17E-7", -0.17E-7f);
|
||||
FloatParseTest("8.7e6", 8.7e6f);
|
||||
FloatParseTest("3.3e-11", 3.3e-11f);
|
||||
FloatParseTest("0.002e5", 0.002e5f);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue