1#!/usr/bin/perl 2 3use strict; 4use warnings; 5use autodie; 6 7use Test::More tests => 2; 8 9my $buffer = 'should-not-appear'; 10eval { 11 read('BOFH', $buffer, 1024); 12}; 13like($@, qr/Can't read\(BOFH, <BUFFER>, 1024\)/, 14 'read should not show the buffer'); 15eval { 16 read('BOFH', $buffer, 1024, 5); 17}; 18like($@, qr/Can't read\(BOFH, <BUFFER>, 1024, 5\)/, 19 'read should not show the buffer'); 20