X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=unit_tests%2Fformat.php;h=0869a7eb79158076b6b09069e2bc9142b7205b17;hb=c3cfa91f3d95f153f6c93dcff421532b9a76b1a7;hp=21a1f74a1cbcb60a4f0df0f90404168e7702647f;hpb=86e64d13d96d22ed84ebf9938e2744a33af77005;p=wfpl.git diff --git a/unit_tests/format.php b/unit_tests/format.php index 21a1f74..0869a7e 100644 --- a/unit_tests/format.php +++ b/unit_tests/format.php @@ -1,6 +1,6 @@ 'Eno', 'two' => 'Owt', 'symbols&\'"' => 'Slobmys'), PULLDOWN_HASH); + $errors +=_test_format_options('hash', 'one', 'one'); + $errors +=_test_format_options('hash', 'One', ''); + $errors +=_test_format_options('hash', 'two', 'two'); + $errors +=_test_format_options('hash', 'symbols&\'"', ''); + pulldown('array_2d', array(array('one', 'Eno'), array('two', 'Owt'), array('symbols&\'"', 'Slobmys')), PULLDOWN_2D); + $errors +=_test_format_options('array_2d', 'one', 'one'); + $errors +=_test_format_options('array_2d', 'One', ''); + $errors +=_test_format_options('array_2d', 'two', 'two'); + $errors +=_test_format_options('array_2d', 'symbols&\'"', ''); + + return $errors; +} + +# returns number of errors function format_unit_tests_main() { $errors = 0; $errors += test_format_money(); $errors += test_format_misc(); + $errors += test_format_options(); return $errors; }