1--TEST--
2time_nanosleep — Delay for a number of seconds and nanoseconds
3--SKIPIF--
4<?php
5if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') die("skip Test is not valid for Windows");
6if (!function_exists('time_nanosleep')) die("skip");
7?>
8--CREDITS--
9Àlex Corretgé - alex@corretge.cat
10--FILE--
11<?php
12
13time_nanosleep(0, -10);
14
15?>
16--EXPECTF--
17Fatal error: Uncaught ValueError: time_nanosleep(): Argument #2 ($nanoseconds) must be greater than or equal to 0 in %s:%d
18Stack trace:
19#0 %s(%d): time_nanosleep(0, -10)
20#1 {main}
21  thrown in %s on line %d
22