Bug 21597: Data too long for column 'invitekey'

Fix t/db_dependent/Virtualshelves.t

virtualshelfshares.invitekey
  `invitekey` varchar(10) COLLATE utf8mb4_unicode_ci DEFAULT NULL,

We should not insert a longer string!

DBIx::Class::Storage::DBI::_dbh_execute(): Data too long for column
'invitekey' at row 1 at /home/vagrant/kohaclone/Koha/Object.pm line 125

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
(cherry picked from commit f19a992095)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
This commit is contained in:
Jonathan Druart 2018-10-17 19:18:58 -03:00 committed by Martin Renvoize
parent f8063726ba
commit e70b624bc6
No known key found for this signature in database
GPG Key ID: 422B469130441A0F
1 changed files with 2 additions and 2 deletions

View File

@ -153,9 +153,9 @@ subtest 'Sharing' => sub {
is( $number_of_shelves_shared, 2, 'To be sure no shares have been removed' );
# Test double accept (BZ 11943) before removing the accepted share
my $third_share = $shelf_to_share->share('valid key number 2');
my $third_share = $shelf_to_share->share('valid key3');
is( Koha::Virtualshelfshares->search->count, 3, 'Three shares' );
$is_accepted = $third_share->accept( 'valid key number 2', $share_with_me->{borrowernumber} );
$is_accepted = $third_share->accept( 'valid key3', $share_with_me->{borrowernumber} );
is( $is_accepted->shelfnumber, $shelf_to_share->shelfnumber, 'Accept returned the existing share' );
is( Koha::Virtualshelfshares->search->count, 2, 'Check that number of shares went down again' );