`allow_any_instance_of(GenericFile).to receive(:characterize_if_changed).and_yield`