Bug 19937 - Silence warnings t/db_dependent/www/batch.t
Summary: Silence warnings t/db_dependent/www/batch.t
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Test Suite (show other bugs)
Version: master
Hardware: All All
: P5 - low trivial (vote)
Assignee: Mark Tompsett
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-09 14:36 UTC by Mark Tompsett
Modified: 2019-10-14 19:57 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 19937: Silence warnings t/db_dependent/www/batch.t (2.57 KB, patch)
2018-01-09 14:43 UTC, Mark Tompsett
Details | Diff | Splinter Review
Bug 19937: Silence warnings t/db_dependent/www/batch.t (2.62 KB, patch)
2018-01-10 16:30 UTC, Lee Jamison
Details | Diff | Splinter Review
Bug 19937: Silence warnings t/db_dependent/www/batch.t (2.87 KB, patch)
2018-01-12 08:41 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Tompsett 2018-01-09 14:36:10 UTC
sudo koha-shell -c bash kohadev
prove t/db_dependent/www/batch.t
cat /var/log/koha/kohadev/plack-error.log

The following errors are triggered:
Use of uninitialized value in array element at /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 50.
Use of uninitialized value $results_per_page in numeric eq (==) at /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 53.
Use of uninitialized value in uc at /home/vagrant/kohaclone/C4/ImportBatch.pm line 1120.
Comment 1 Mark Tompsett 2018-01-09 14:43:38 UTC
Created attachment 70364 [details] [review]
Bug 19937: Silence warnings t/db_dependent/www/batch.t

TEST PLAN
---------
1) Run the following on a kohadevbox:
    git checkout -b bug_19937 origin/master
    sudo koha-shell -c bash kohadev
    prove t/db_dependent/www/batch.t
    cat /var/log/koha/kohadev/plack-error.log

    The following errors are triggered at the end of the log file:
        Use of uninitialized value in array element at
        /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 50.
        Use of uninitialized value $results_per_page in numeric eq (==) at
        /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 53.
        Use of uninitialized value in uc at
        /home/vagrant/kohaclone/C4/ImportBatch.pm line 1120.

2) Run the following on a kohadevbox:
    exit
    git bz apply 19937
    restart_all
    sudo koha-shell -c bash kohadev
    prove t/db_dependent/www/batch.t
    cat /var/log/koha/kohadev/plack-error.log

    The log file will end with the restarting of plack, not the
    errors.

3) run koha qa test tools
Comment 2 Lee Jamison 2018-01-10 16:30:25 UTC
Created attachment 70410 [details] [review]
Bug 19937: Silence warnings t/db_dependent/www/batch.t

TEST PLAN
---------
1) Run the following on a kohadevbox:
    git checkout -b bug_19937 origin/master
    sudo koha-shell -c bash kohadev
    prove t/db_dependent/www/batch.t
    cat /var/log/koha/kohadev/plack-error.log

    The following errors are triggered at the end of the log file:
        Use of uninitialized value in array element at
        /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 50.
        Use of uninitialized value $results_per_page in numeric eq (==) at
        /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 53.
        Use of uninitialized value in uc at
        /home/vagrant/kohaclone/C4/ImportBatch.pm line 1120.

2) Run the following on a kohadevbox:
    exit
    git bz apply 19937
    restart_all
    sudo koha-shell -c bash kohadev
    prove t/db_dependent/www/batch.t
    cat /var/log/koha/kohadev/plack-error.log

    The log file will end with the restarting of plack, not the
    errors.

3) run koha qa test tools

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>
Comment 3 Marcel de Rooy 2018-01-12 08:41:42 UTC
Created attachment 70447 [details] [review]
Bug 19937: Silence warnings t/db_dependent/www/batch.t

TEST PLAN
---------
1) Run the following on a kohadevbox:
    git checkout -b bug_19937 origin/master
    sudo koha-shell -c bash kohadev
    prove t/db_dependent/www/batch.t
    cat /var/log/koha/kohadev/plack-error.log

    The following errors are triggered at the end of the log file:
        Use of uninitialized value in array element at
        /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 50.
        Use of uninitialized value $results_per_page in numeric eq (==) at
        /home/vagrant/kohaclone/tools/batch_records_ajax.pl line 53.
        Use of uninitialized value in uc at
        /home/vagrant/kohaclone/C4/ImportBatch.pm line 1120.

2) Run the following on a kohadevbox:
    exit
    git bz apply 19937
    restart_all
    sudo koha-shell -c bash kohadev
    prove t/db_dependent/www/batch.t
    cat /var/log/koha/kohadev/plack-error.log

    The log file will end with the restarting of plack, not the
    errors.

3) run koha qa test tools

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Amended handling of $results_per_page.
Comment 4 Jonathan Druart 2018-01-15 15:25:53 UTC
Pushed to master for 18.05, thanks to everybody involved!
Comment 5 Nick Clemens 2018-01-23 04:08:47 UTC
Awesome work all!

Pushed to Stable for 17.11.02
Comment 6 Fridolin Somers 2018-01-31 07:28:51 UTC
Pushed to 17.05.x for v17.05.09