matched code from pragprog depot_r  for line_item fixture