=================================================================== RCS file: /cvs/palm/Palm-Keyring/t/keyring.t,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- palm/Palm-Keyring/t/keyring.t 2008/09/18 02:53:27 1.18 +++ palm/Palm-Keyring/t/keyring.t 2008/09/18 03:02:50 1.19 @@ -1,5 +1,5 @@ #!/usr/bin/perl -T -# $RedRiver: keyring.t,v 1.17 2007/09/13 15:41:36 andrew Exp $ +# $RedRiver: keyring.t,v 1.18 2008/09/18 01:53:27 andrew Exp $ use strict; use warnings; @@ -25,42 +25,42 @@ }, ); - my $acct = { - 0 => { - label => 'name', - label_id => 0, - data => 'test3', - font => 0, +my $acct = { + 0 => { + label => 'name', + label_id => 0, + data => 'test3', + font => 0, + }, + 1 => { + label => 'account', + label_id => 1, + data => 'atestaccount', + font => 0, + }, + 2 => { + label => 'password', + label_id => 2, + data => $password, + font => 0, + }, + 3 => { + label => 'lastchange', + label_id => 3, + data => { + day => 2, + month => 2, + year => 99, }, - 1 => { - label => 'account', - label_id => 1, - data => 'atestaccount', - font => 0, - }, - 2 => { - label => 'password', - label_id => 2, - data => $password, - font => 0, - }, - 3 => { - label => 'lastchange', - label_id => 3, - data => { - day => 2, - month => 2, - year => 99, - }, - font => 0, - }, - 255 => { - label => 'notes', - label_id => 255, - data => 'now that really roxorZ!', - font => 0, - }, - }; + font => 0, + }, + 255 => { + label => 'notes', + label_id => 255, + data => 'now that really roxorZ!', + font => 0, + }, +}; foreach my $options (@o) { my $pdb; @@ -102,7 +102,7 @@ $pdb = undef; - ok( $pdb = new Palm::PDB(), 'new Palm::Keyring' ); + ok( $pdb = new Palm::Keyring(), 'new Palm::Keyring' ); ok( $pdb->Load($file), 'Load File' ); @@ -128,9 +128,9 @@ is_deeply( $old_date, $new_date, 'Date didn\'t change' ); - $acct->{2}->{data} = $new_password; + $decrypted->{2}->{data} = $new_password; - $pdb->{records}->[$rec_num]->{plaintext} = $acct; + $pdb->{records}->[$rec_num]->{plaintext} = $decrypted; ok( $pdb->Encrypt( $pdb->{'records'}->[$rec_num] ), 'Change record' );