From c659ab03e0b63d4af16b11cd65feb81756335858 Mon Sep 17 00:00:00 2001 From: Chris Cromer Date: Wed, 16 Jan 2019 21:14:39 -0300 Subject: [PATCH] remove old test files --- test/money.vala | 15 --------------- test/percentage.vala | 18 ------------------ test/rut.vala | 36 ------------------------------------ 3 files changed, 69 deletions(-) delete mode 100644 test/money.vala delete mode 100644 test/percentage.vala delete mode 100644 test/rut.vala diff --git a/test/money.vala b/test/money.vala deleted file mode 100644 index cb82b8d..0000000 --- a/test/money.vala +++ /dev/null @@ -1,15 +0,0 @@ -using LibSernatur.Misc; - -void add_money_tests () { - Test.add_func ("/sernatur/test/money", () => { - assert (Money.format_int (100000) == "$100.000"); - assert (Money.format_uint (100000) == "$100.000"); - assert (Money.format_string ("100000") == "$100.000"); - }); -} - -int main (string[] args) { - Test.init (ref args); - add_money_tests (); - return Test.run (); -} diff --git a/test/percentage.vala b/test/percentage.vala deleted file mode 100644 index acc295a..0000000 --- a/test/percentage.vala +++ /dev/null @@ -1,18 +0,0 @@ -using LibSernatur.Misc; - -void add_percentage_tests () { - Test.add_func ("/sernatur/test/percentage", () => { - assert (Percentage.format_float ((float) 0.07) == "7%"); - assert (Percentage.format_float ((float) 0.43) == "43%"); - assert (Percentage.format_float ((float) 1) == "100%"); - assert (Percentage.format_double (0.07) == "7%"); - assert (Percentage.format_double (0.43) == "43%"); - assert (Percentage.format_double (1) == "100%"); - }); -} - -int main (string[] args) { - Test.init (ref args); - add_percentage_tests (); - return Test.run (); -} diff --git a/test/rut.vala b/test/rut.vala deleted file mode 100644 index c315a79..0000000 --- a/test/rut.vala +++ /dev/null @@ -1,36 +0,0 @@ -using LibSernatur.Misc; - -void add_rut_tests () { - Test.add_func ("/sernatur/test/rut", () => { - try { - Rut rut = new Rut ("18166316-2"); - assert (rut.get_clean_rut () == "181663162"); - assert (rut.get_rut () == "18.166.316-2"); - assert (rut.type () == Rut.Type.RUN); - - rut = new Rut ("181663162"); - assert (rut.get_clean_rut () == "181663162"); - assert (rut.get_rut () == "18.166.316-2"); - assert (rut.type () == Rut.Type.RUN); - - rut = new Rut ("20.380.508-k"); - assert (rut.get_clean_rut () == "20380508K"); - assert (rut.get_rut () == "20.380.508-K"); - assert (rut.type () == Rut.Type.RUN); - - rut = new Rut ("50380508-1"); - assert (rut.get_clean_rut () == "503805081"); - assert (rut.get_rut () == "50.380.508-1"); - assert (rut.type () == Rut.Type.RUT); - } - catch (Error e) { - error (e.message); - } - }); -} - -int main (string[] args) { - Test.init (ref args); - add_rut_tests (); - return Test.run (); -}