| Lines 914-920
          subtest 'can_update_pickup_location_opac() tests' => sub {
      
      
        Link Here | 
        
          | 914 |  | 914 |  | 
        
          | 915 | subtest 'change_type tests' => sub { | 915 | subtest 'change_type tests' => sub { | 
        
          | 916 |  | 916 |  | 
          
            
              | 917 |     plan tests => 9; | 917 |     plan tests => 13; | 
        
          | 918 |  | 918 |  | 
        
          | 919 |     $schema->storage->txn_begin; | 919 |     $schema->storage->txn_begin; | 
        
          | 920 |  | 920 |  | 
  
    | Lines 923-928
          subtest 'change_type tests' => sub {
      
      
        Link Here | 
        
          | 923 |         class => 'Koha::Holds', | 923 |         class => 'Koha::Holds', | 
        
          | 924 |         value => { | 924 |         value => { | 
        
          | 925 |             itemnumber => undef, | 925 |             itemnumber => undef, | 
            
              |  |  | 926 |             item_level_hold => 0, | 
        
          | 926 |         } | 927 |         } | 
        
          | 927 |     } ); | 928 |     } ); | 
        
          | 928 |  | 929 |  | 
  
    | Lines 939-962
          subtest 'change_type tests' => sub {
      
      
        Link Here | 
        
          | 939 |  | 940 |  | 
        
          | 940 |     is( $hold->itemnumber, undef, 'record hold to record hold, no changes'); | 941 |     is( $hold->itemnumber, undef, 'record hold to record hold, no changes'); | 
        
          | 941 |  | 942 |  | 
            
              |  |  | 943 |     is( $hold->item_level_hold, 0, 'item_level_hold=0' ); | 
            
              | 944 |  | 
        
          | 942 |     ok( $hold->change_type( $item->itemnumber ) ); | 945 |     ok( $hold->change_type( $item->itemnumber ) ); | 
        
          | 943 |  | 946 |  | 
        
          | 944 |     $hold->discard_changes; | 947 |     $hold->discard_changes; | 
        
          | 945 |  | 948 |  | 
        
          | 946 |     is( $hold->itemnumber, $item->itemnumber, 'record hold to item hold'); | 949 |     is( $hold->itemnumber, $item->itemnumber, 'record hold to item hold'); | 
        
          | 947 |  | 950 |  | 
            
              |  |  | 951 |     is( $hold->item_level_hold, 1, 'item_level_hold=1' ); | 
            
              | 952 |  | 
        
          | 948 |     ok( $hold->change_type( $item->itemnumber ) ); | 953 |     ok( $hold->change_type( $item->itemnumber ) ); | 
        
          | 949 |  | 954 |  | 
        
          | 950 |     $hold->discard_changes; | 955 |     $hold->discard_changes; | 
        
          | 951 |  | 956 |  | 
        
          | 952 |     is( $hold->itemnumber, $item->itemnumber, 'item hold to item hold, no changes'); | 957 |     is( $hold->itemnumber, $item->itemnumber, 'item hold to item hold, no changes'); | 
        
          | 953 |  | 958 |  | 
            
              |  |  | 959 |     is( $hold->item_level_hold, 1, 'item_level_hold=1' ); | 
            
              | 960 |  | 
        
          | 954 |     ok( $hold->change_type ); | 961 |     ok( $hold->change_type ); | 
        
          | 955 |  | 962 |  | 
        
          | 956 |     $hold->discard_changes; | 963 |     $hold->discard_changes; | 
        
          | 957 |  | 964 |  | 
        
          | 958 |     is( $hold->itemnumber, undef, 'item hold to record hold'); | 965 |     is( $hold->itemnumber, undef, 'item hold to record hold'); | 
        
          | 959 |  | 966 |  | 
            
              |  |  | 967 |     is( $hold->item_level_hold, 0, 'item_level_hold=0' ); | 
            
              | 968 |  | 
        
          | 960 |     my $hold3 = $builder->build_object( { | 969 |     my $hold3 = $builder->build_object( { | 
        
          | 961 |         class => 'Koha::Holds', | 970 |         class => 'Koha::Holds', | 
        
          | 962 |         value => { | 971 |         value => { | 
            
              | 963 | -  |  |  |