[Fix #3375] on the API display safe files only
This commit is contained in:
parent
0dbe880f51
commit
f7650135f4
3 changed files with 29 additions and 2 deletions
|
@ -8,7 +8,10 @@ describe ChampSerializer do
|
|||
|
||||
let(:champ) { create(:champ_piece_justificative) }
|
||||
|
||||
before { champ.piece_justificative_file.attach({ filename: __FILE__, io: File.open(__FILE__) }) }
|
||||
before do
|
||||
champ.piece_justificative_file.attach({ filename: __FILE__, io: File.open(__FILE__) })
|
||||
champ.reload.virus_scan.safe!
|
||||
end
|
||||
after { champ.piece_justificative_file.purge }
|
||||
|
||||
it { is_expected.to include(value: url_for(champ.piece_justificative_file)) }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue