https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23681
Tomás Cohen Arazi <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Failed QA --- Comment #317 from Tomás Cohen Arazi <[email protected]> --- Ok, this is almost done. I added some required follow-ups. But the remaining things are too much for me to take care right now, so failing it and adding my (not so big) list: - The test files should be moved to Koha/RestrictionType*.t [MINOR] - The tests do not cover all the things. They are also mixed. The RestrictionType.t file tests Koha::RestrictionTypes->keyed_on_code - Koha::RestrictionTypes->keyed_on_code is not really required... and is very different than our normal return values... The fact we need to delete everything in order to test it points to some design issue (i.e. it is not a method that acts on $self as a resultset, but works in the whole table. - keyed_on_code should be replaced by something along the lines of: { map { $_->{code} => $_ } $self->as_list } - Koha::RestrictionType->make_default looks great :-D - Koha::RestrictionType->delete has problems. We *could* accept it using plain SQL, but the logic is wrong. If the type is a system one, and exception should be thrown. The same if it is the default ;-) (i.e. it is setting itself as default (again) and then deleting itself). As you can see, we are close to pushing this. Please hurry so no rebases are needed. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
