Use documentables helper method within specs and document model.

This commit is contained in:
Senén Rodero Rodríguez
2017-07-24 14:34:09 +02:00
parent 17ad148cd7
commit 92e8468e89
5 changed files with 28 additions and 10 deletions

View File

@@ -3,6 +3,7 @@ shared_examples "document validations" do |documentable_factory|
include DocumentablesHelper
let!(:document) { build(:document, documentable_factory.to_sym) }
let!(:documentable) { document.documentable }
let!(:maxfilesize) { max_file_size(document.documentable) }
let!(:acceptedcontenttypes) { accepted_content_types(document.documentable) }