File: set_large.phpt

package info (click to toggle)
php-memcached 3.3.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 924 kB
  • sloc: ansic: 5,161; xml: 869; php: 343; pascal: 81; sh: 12; makefile: 5
file content (19 lines) | stat: -rw-r--r-- 382 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
--TEST--
set large data
--SKIPIF--
<?php include "skipif.inc";?>
--FILE--
<?php
include dirname (__FILE__) . '/config.inc';
$m = memc_get_instance (array (
	Memcached::OPT_ITEM_SIZE_LIMIT => 0,
));

$key = 'foobarbazDEADC0DE';
$value = str_repeat("foo bar", 1024 * 1024);
var_dump($m->set($key, $value, 360));
var_dump($m->get($key) === $value);
?>
--EXPECT--
bool(true)
bool(true)