1--TEST--
2Test exif_tagname() function : error conditions
3--SKIPIF--
4<?php if (!extension_loaded('exif')) print 'skip exif extension not available';?>
5--FILE--
6<?php
7
8/* Prototype  :string exif_tagname ( string $index  )
9 * Description: Get the header name for an index
10 * Source code: ext/exif/exif.c
11*/
12
13echo "*** Testing exif_tagname() : error conditions ***\n";
14
15echo "\n-- Testing exif_tagname() function with no arguments --\n";
16var_dump( exif_tagname() );
17
18echo "\n-- Testing exif_tagname() function with more than expected no. of arguments --\n";
19$extra_arg = 10;
20var_dump( exif_tagname(0x10E, $extra_arg) );
21
22?>
23===Done===
24--EXPECTF--
25*** Testing exif_tagname() : error conditions ***
26
27-- Testing exif_tagname() function with no arguments --
28
29Warning: exif_tagname() expects exactly 1 parameter, 0 given in %s on line %d
30NULL
31
32-- Testing exif_tagname() function with more than expected no. of arguments --
33
34Warning: exif_tagname() expects exactly 1 parameter, 2 given in %s on line %d
35NULL
36===Done===
37
38