aboutsummaryrefslogtreecommitdiffstats
path: root/spec/spec_helper.rb
diff options
context:
space:
mode:
authorSeb Bacon <seb.bacon@gmail.com>2011-12-13 17:27:39 +0000
committerSeb Bacon <seb.bacon@gmail.com>2011-12-13 17:27:39 +0000
commit4075d5a70a6e08c1d55e97dbfc13fda4a2faaf84 (patch)
treef46f09858bc4140394e60fe0f37a8ee15a8d134a /spec/spec_helper.rb
parent8405aeefaf1b4f72e1bc781995547d775e8991d7 (diff)
Further improvements to attachment caching
Diffstat (limited to 'spec/spec_helper.rb')
-rw-r--r--spec/spec_helper.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index e5a42f1a9..5c5cd9a7f 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -78,6 +78,7 @@ def load_file_fixture(file_name)
end
def rebuild_xapian_index(terms = true, values = true, texts = true, dropfirst = true)
+ parse_all_incoming_messages
if dropfirst
begin
ActsAsXapian.readable_init
@@ -168,3 +169,7 @@ def load_raw_emails_data(raw_emails)
end
raw_email.data = load_file_fixture("useless_raw_email.email")
end
+
+def parse_all_incoming_messages
+ IncomingMessage.find(:all).each{|x| x.parse_raw_email!}
+end