~yolanda.robla/ubuntu/trusty/memcached/add_distribution

« back to all changes in this revision

Viewing changes to t/issue_108.t

  • Committer: Bazaar Package Importer
  • Author(s): David Martínez Moreno
  • Date: 2010-05-12 11:41:22 UTC
  • mfrom: (1.1.7 upstream) (3.3.3 squeeze)
  • Revision ID: james.westby@ubuntu.com-20100512114122-e2dphwiezevuny1t
Tags: 1.4.5-1
* New upstream release.  Main changes since 1.4.2 are:
  New features:
  - Support for SASL authentication.
  - New script damemtop - a memcached top.
  - Slab optimizations.
  - New stats, for reclaimed memory and SASL events.
  Bugs fixed:
  - Malicious input can crash server (CVE-2010-1152).  Closes: #579913.
  - Fixed several problems with slab handling and growth.
  - Provide better error reporting.
  - Fix get stats accounting.
  - Fixed backwards compatibility with delete 0.
  - Documentation fixes.
  - Various build fixes, among others, fixed FTBFS with gcc-4.5 (closes:
    #565033).
* Refreshed and renamed 01_init_script_compliant_with_LSB.patch.
* Fixed lintian warnings by adding $remote_fs to init.d script.
* Removed non-existent document (doc/memory_management.txt).
* debian/control: Bumped Standards-Version to 3.8.4 (no changes).

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/perl
 
2
 
 
3
use strict;
 
4
use Test::More tests => 4;
 
5
use FindBin qw($Bin);
 
6
use lib "$Bin/lib";
 
7
use MemcachedTest;
 
8
 
 
9
my $server = new_memcached();
 
10
my $sock = $server->sock;
 
11
my $key = "del_key";
 
12
 
 
13
print $sock "add $key 0 0 1\r\nx\r\n";
 
14
is (scalar <$sock>, "STORED\r\n", "Added a key");
 
15
 
 
16
print $sock "delete $key 0\r\n";
 
17
is (scalar <$sock>, "DELETED\r\n", "Properly deleted with 0");
 
18
 
 
19
print $sock "add $key 0 0 1\r\nx\r\n";
 
20
is (scalar <$sock>, "STORED\r\n", "Added again a key");
 
21
 
 
22
print $sock "delete $key 0 noreply\r\n";
 
23
# will not reply, but a subsequent add will succeed
 
24
 
 
25
print $sock "add $key 0 0 1\r\nx\r\n";
 
26
is (scalar <$sock>, "STORED\r\n", "Add succeeded after quiet deletion.");
 
27