aboutsummaryrefslogtreecommitdiffstats
path: root/spec/factories/foi_attchments.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/factories/foi_attchments.rb')
-rw-r--r--spec/factories/foi_attchments.rb21
1 files changed, 21 insertions, 0 deletions
diff --git a/spec/factories/foi_attchments.rb b/spec/factories/foi_attchments.rb
new file mode 100644
index 000000000..4e9875a00
--- /dev/null
+++ b/spec/factories/foi_attchments.rb
@@ -0,0 +1,21 @@
+FactoryGirl.define do
+
+ factory :foi_attachment do
+ factory :body_text do
+ content_type 'text/plain'
+ body { 'hereisthetext' }
+ filename 'attachment.txt'
+ end
+ factory :pdf_attachment do
+ content_type 'application/pdf'
+ filename 'interesting.pdf'
+ body { load_file_fixture('interesting.pdf') }
+ end
+ factory :rtf_attachment do
+ content_type 'application/rtf'
+ filename 'interesting.rtf'
+ body { load_file_fixture('interesting.rtf') }
+ end
+ end
+
+end