Added in some missing fields (columns) to watchman_events tables
[hiphop-php.git] / hphp / test / zend / good / ext / standard / tests / array / array_unique_error.php
blob283842d20358b41217af0d9cf9d0caa99882ae30
1 <?hh
2 /* Prototype : array array_unique(array $input)
3 * Description: Removes duplicate values from array
4 * Source code: ext/standard/array.c
5 */
6 <<__EntryPoint>> function main(): void {
7 echo "*** Testing array_unique() : error conditions ***\n";
9 // Zero arguments
10 echo "\n-- Testing array_unique() function with zero arguments --\n";
11 try { var_dump( array_unique() ); } catch (Exception $e) { echo "\n".'Warning: '.$e->getMessage().' in '.__FILE__.' on line '.__LINE__."\n"; }
13 //Test array_unique with one more than the expected number of arguments
14 echo "\n-- Testing array_unique() function with more than expected no. of arguments --\n";
15 $input = vec[1, 2];
16 $extra_arg = 10;
17 try { var_dump( array_unique($input, SORT_NUMERIC, $extra_arg) ); } catch (Exception $e) { echo "\n".'Warning: '.$e->getMessage().' in '.__FILE__.' on line '.__LINE__."\n"; }
19 echo "Done";