Bug 13075: Silence warnings and improve Charset testing.
authorMark Tompsett <mtompset@hotmail.com>
Sun, 12 Oct 2014 00:02:35 +0000 (20:02 -0400)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Fri, 14 Nov 2014 12:35:44 +0000 (09:35 -0300)
commit878fa77c30732eb5f37f9bd050286b10b74fb881
tree9613146916ccbadd21db42bee21b6dabc27e6fda
parent628aea461aac5261ad8ab7880af2865d0128f760
Bug 13075: Silence warnings and improve Charset testing.

Calls to C4/Charset.pm's NormalizeString function with an
undefined string were triggering warnings when running:
  prove -v t/db_dependent/Holds.t

Sadly, t/Charset.t was also lacking calls to NormalizeString.

TEST PLAN
---------
1) prove -v t/db_dependent/Holds.t
   -- This should generate the uninitialized string warnings.
      Make sure CPL and MPL are in your branches to save
      yourself from headaches due to expected data.
2) cat t/Charset.t
   -- note there are no function calls to NormalizeString.
      You can see other shortfalls in the tests beyond
      NormalizeString with: grep ^sub C4/Charset.pm
3) prove -v t/Charset.t
4) Apply patch
5) prove -v t/Charset.t
   -- Run as before with more tests.
6) cat t/Charset.t
   -- note there are now function calls to NormalizeString.
7) prove -v t/db_dependent/Holds.t
   -- Nice and clean run! :)
8) koha-qa.pl -v 2 -c 1
   -- all should be Ok.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
C4/Charset.pm
t/Charset.t