From 9f478de2ca65b2775624d244df12f4e26bb5d208 Mon Sep 17 00:00:00 2001 From: Shitiz Garg Date: Wed, 18 Jun 2014 15:34:06 +0530 Subject: [PATCH] [ticket/12514] Add a few additional tests for type_dropdown PHPBB3-12514 --- tests/profilefields/type_dropdown_test.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tests/profilefields/type_dropdown_test.php b/tests/profilefields/type_dropdown_test.php index ddc34f221f..ec68f0e77e 100644 --- a/tests/profilefields/type_dropdown_test.php +++ b/tests/profilefields/type_dropdown_test.php @@ -82,6 +82,18 @@ class phpbb_profilefield_type_dropdown_test extends phpbb_test_case 'FIELD_INVALID_VALUE-field', 'Invalid value should throw error', ), + array( + true, + array('field_required' => true), + false, + 'Boolean would evaluate to 1 and hence correct value', + ), + array( + 'string', + array('field_required' => true), + 'FIELD_REQUIRED-field', + 'String should be rejected for value', + ), array( 2, array(),