|
15 | 15 | ok - 2 args
|
16 | 16 | ok - 3 args
|
17 | 17 | ok - 4 args
|
| 18 | +ok - 4 args |
| 19 | +ok - 4 args |
| 20 | +ok - 4 args |
18 | 21 | ok - 5 args
|
19 | 22 | ok - 6 args
|
20 | 23 | */
|
|
32 | 35 | tap_equal(null, newrelic_notice_error("", 42), "2 args");
|
33 | 36 | tap_equal(null, newrelic_notice_error("", array()), "2 args");
|
34 | 37 |
|
35 |
| -// Three and four argument forms are not allowed. |
| 38 | +// Three argument forms are not allowed. |
36 | 39 | tap_equal(null, newrelic_notice_error(42, "message", "file"), "3 args");
|
37 |
| -tap_equal(null, newrelic_notice_error(42, "message", "file", __LINE__), "4 args"); |
| 40 | + |
| 41 | +// Four argument form requires integer, string, string, integer |
| 42 | +// This is like the five argument form but for PHP 8+ where the context is not supplied |
| 43 | +tap_equal(null, newrelic_notice_error("", "message", "file", __LINE__), "4 args"); |
| 44 | +tap_equal(null, newrelic_notice_error(42, array(), "file", __LINE__), "4 args"); |
| 45 | +tap_equal(null, newrelic_notice_error("", "message", array(), __LINE__), "4 args"); |
| 46 | +tap_equal(null, newrelic_notice_error("", "message", "file", ""), "4 args"); |
38 | 47 |
|
39 | 48 | // Five argument form requires second arg to be convertible to a string.
|
40 | 49 | tap_equal(null, newrelic_notice_error("", curl_init()), "5 args");
|
|
0 commit comments