File: 005.phpt

package info (click to toggle)
php-zstd 0.14.0-1.1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,536 kB
  • sloc: ansic: 30,009; asm: 382; xml: 179; makefile: 3
file content (34 lines) | stat: -rw-r--r-- 840 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
--TEST--
zstd_uncompress(): error conditions
--SKIPIF--
<?php
if (PHP_VERSION_ID >= 80000) die("skip requires PHP < 8.0");
--FILE--
<?php

echo "*** Testing zstd_uncompress() function with Zero arguments ***", PHP_EOL;
var_dump( zstd_uncompress() );

echo "*** Testing with incorrect arguments ***", PHP_EOL;
var_dump(zstd_uncompress(123));

class Tester
{}

$testclass = new Tester();
var_dump(zstd_uncompress($testclass));
?>
===DONE===
--EXPECTF--
*** Testing zstd_uncompress() function with Zero arguments ***

Warning: zstd_uncompress() expects exactly 1 parameter, 0 given in %s on line %d
bool(false)
*** Testing with incorrect arguments ***

Warning: zstd_uncompress(): expects parameter to be string. in %s on line %d
bool(false)

Warning: zstd_uncompress(): expects parameter to be string. in %s on line %d
bool(false)
===DONE===