Bug 13455

Summary: Members/AddEnrolmentFeeIfNeeded.t requires sample data
Product: Koha Reporter: Mark Tompsett <mtompset>
Component: Test SuiteAssignee: Mark Tompsett <mtompset>
Status: RESOLVED DUPLICATE QA Contact: Galen Charlton <gmcharlt>
Severity: minor    
Priority: P5 - low CC: jonathan.druart, katrin.fischer, magnus
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Bug 13455: Members/AddEnrolmentFeeIfNeeded.t requires sample data
Bug 13455: Members/AddEnrolmentFeeIfNeeded.t requires sample data

Description Mark Tompsett 2014-12-12 20:40:06 UTC
While trying to debug, I found prove t/db_dependent/Members/AddEnrolmentFeeIfNeeded.t failed if sample data wasn't in the database. This should be fixed.
Comment 1 Mark Tompsett 2014-12-12 20:49:57 UTC Comment hidden (obsolete)
Comment 2 Magnus Enger 2015-02-18 21:16:35 UTC
Created attachment 36008 [details] [review]
Bug 13455: Members/AddEnrolmentFeeIfNeeded.t requires sample data

TEST PLAN
---------
1) Make sure there are no 'J', 'K', nor 'YA' patron category codes.
2) Make sure there are no 'CPL' nor 'MPL' branch codes.
3) prove t/db_dependent/Members/AddEnrolmentFeeIfNeeded.t
   -- dies horribly
4) apply patch
5) prove t/db_dependent/Members/AddEnrolmentFeeIfNeeded.t
   -- passes
6) Run koha qa test tools

Signed-off-by: Magnus Enger <magnus@enger.priv.no>
For me, the tests fail because I have a Norweian setup with different
categories etc. After applying the patch the tests pass.
Comment 3 Jonathan Druart 2015-02-19 09:27:24 UTC
I still completely disagree with this kind of patch, see my comments on bug 13457.
Comment 4 Katrin Fischer 2015-02-22 12:23:37 UTC
Moving this to "In Discussion".
Comment 5 Katrin Fischer 2023-07-28 20:30:27 UTC
(In reply to Jonathan Druart from comment #3)
> I still completely disagree with this kind of patch, see my comments on bug
> 13457.

Have we settled on assuming the sample data is available?
Comment 6 Jonathan Druart 2023-08-01 06:38:27 UTC
(In reply to Katrin Fischer from comment #5)
> (In reply to Jonathan Druart from comment #3)
> > I still completely disagree with this kind of patch, see my comments on bug
> > 13457.
> 
> Have we settled on assuming the sample data is available?

use TestBuilder.
Comment 7 Jonathan Druart 2023-08-01 06:40:04 UTC
And this is what did this commit

  commit f9654783e2154bfd95cac92ae9b23615d88538e2
  Bug 16912: Koha::Patrons - Move and rewrite tests for AddEnrolmentFeeIfNeeded

*** This bug has been marked as a duplicate of bug 16912 ***