Fix failing spec.

This commit is contained in:
Guo Xiang Tan 2019-04-16 09:59:35 +08:00
parent ce4c8e957b
commit d6e45864ce
2 changed files with 4 additions and 5 deletions
app/jobs/regular
spec/jobs

@ -30,8 +30,7 @@ module Jobs
ensure ensure
# send notification to user regarding progress # send notification to user regarding progress
notify_user notify_user
File.delete(csv_path) if csv_path
FileUtils.rm_rf(csv_path) if csv_path
end end
private private

@ -13,9 +13,9 @@ describe Jobs::BulkInvite do
let(:filename) { "#{Invite.base_directory}/#{basename}" } let(:filename) { "#{Invite.base_directory}/#{basename}" }
before do before do
FileUtils.cp( Invite.create_csv(
"#{Rails.root}/spec/fixtures/csv/#{basename}", fixture_file_upload("#{Rails.root}/spec/fixtures/csv/#{basename}"),
filename "bulk_invite"
) )
end end