@@ -, +, @@ --- Koha/Item/Transfer.pm | 6 +++--- t/db_dependent/Koha/Item/Transfer.t | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) --- a/Koha/Item/Transfer.pm +++ a/Koha/Item/Transfer.pm @@ -84,19 +84,19 @@ sub transit { return $self; } -=head3 receipt +=head3 receive Receive the transfer by setting the datearrived time. =cut -sub receipt { +sub receive { my ($self) = @_; # Throw exception if item is checked out Koha::Exceptions::Item::Transfer::Out->throw() if ($self->item->checkout); - # Update the receipt state + # Update the arrived date $self->set({ datearrived => dt_from_string })->store; ModDateLastSeen( $self->item->itemnumber ); --- a/t/db_dependent/Koha/Item/Transfer.t +++ a/t/db_dependent/Koha/Item/Transfer.t @@ -113,7 +113,7 @@ subtest 'transit tests' => sub { $schema->storage->txn_rollback; }; -subtest 'receipt tests' => sub { +subtest 'receive tests' => sub { plan tests => 5; $schema->storage->txn_begin; @@ -153,7 +153,7 @@ subtest 'receipt tests' => sub { ); is( ref($checkout), 'Koha::Checkout', 'Mock checkout added' ); - throws_ok { $transfer->receipt() } + throws_ok { $transfer->receive() } 'Koha::Exceptions::Item::Transfer::Out', 'Exception thrown if item is checked out'; @@ -161,7 +161,7 @@ subtest 'receipt tests' => sub { # Transit state set $transfer->discard_changes; - $transfer->receipt(); + $transfer->receive(); ok( $transfer->datearrived, 'Receipt set the datearrived for the transfer' ); # Last seen --