this seems to have fixed a nuisance error within our unit-tests. Issue #57
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user