this seems to have fixed a nuisance error within our unit-tests. Issue #57

This commit is contained in:
cktricky
2013-10-22 00:57:32 -04:00
parent 64f2ad9f9e
commit 753840a276
+4 -3
View File
@@ -10,9 +10,10 @@ class Benefits < ActiveRecord::Base
make_backup(file, data_path, full_file_name) if backup == "true"
end
def self.make_backup(file, data_path, full_file_name)
system("cp #{full_file_name} #{data_path}/bak#{Time.now.to_i}_#{file.original_filename}")
# FileUtils.cp "#{full_file_name}", "#{data_path}/bak#{Time.now.to_i}_#{file.original_filename}"
def self.make_backup(*params)
if File.exists?(full_file_name)
system("cp #{full_file_name} #{data_path}/bak#{Time.now.to_i}_#{file.original_filename}")
end
end
=begin