]>
Dogcows Code - chaz/p5-File-KDBX/blob - t/safe.t
79d8e4cf9a4467225af75d0202e62d6c4ad70e43
13 BEGIN { use_ok
'File::KDBX::Safe' }
15 my $secret = 'secret';
19 value
=> 'classified',
30 my $safe = File
::KDBX
::Safe-
>new([@strings, \
$secret]);
31 cmp_deeply \
@strings, [
42 ], 'Encrypt strings in a safe' or diag explain \
@strings;
43 is $secret, undef, 'Scalar was set to undef';
45 my $val = $safe->peek($strings[1]);
46 is $val, 'bar', 'Peek at a string';
49 cmp_deeply \
@strings, [
51 value
=> 'classified',
60 ], 'Decrypt strings in a safe' or diag explain \
@strings;
61 is $secret, 'secret', 'Scalar was set back to secret';
This page took 0.0458 seconds and 3 git commands to generate.