---
test/test_message.rb | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/test/test_message.rb b/test/test_message.rb
index 0a7db45..675b81d 100644
--- a/test/test_message.rb
+++ b/test/test_message.rb
@@ -73,6 +73,7 @@ EOS
source_info = 0
sup_message = Message.new( {:source => source, :source_info =>
source_info } )
+ sup_message.load_from_source!
# see how well parsing the header went
@@ -222,6 +223,7 @@ EOS
source_info = 0
sup_message = Message.new( {:source => source, :source_info =>
source_info } )
+ sup_message.load_from_source!
# read the message body chunks
@@ -271,6 +273,7 @@ EOS
source_info = 0
sup_message = Message.new( {:source => source, :source_info =>
source_info } )
+ sup_message.load_from_source!
to = sup_message.to
@@ -316,6 +319,7 @@ EOS
source_info = 0
sup_message = Message.new( {:source => source, :source_info =>
source_info } )
+ sup_message.load_from_source!
# read the message body chunks: no errors should reach this level
@@ -414,6 +418,7 @@ EOS
source_info = 0
sup_message = Message.new( {:source => source, :source_info =>
source_info } )
+ sup_message.load_from_source!
# read the message body chunks
@@ -504,6 +509,7 @@ EOS
source_info = 0
sup_message = Message.new( {:source => source, :source_info =>
source_info } )
+ sup_message.load_from_source!
# See how well parsing the message ID went.
id = sup_message.id
--
1.6.0.4
William Morgan
2009-Jul-28 15:12 UTC
[sup-talk] [PATCH] explicitly load messages in testcase
Hi Rich, Not to be a pain, but can you give a little more context for this patch (and the other two you sent recently)? I''m just trying to understand what this fixes. -- William <wmorgan-sup at masanjin.net>
Excerpts from William Morgan''s message of Tue Jul 28 11:12:51 -0400 2009:> Hi Rich, > > Not to be a pain, but can you give a little more context for this patch > (and the other two you sent recently)? I''m just trying to understand > what this fixes.Sure. The commit "don''t automatically parse header on Message#new" broke test_message because the message id/etc fields are nil until load_from_source! is called. This patch just calls load_from_source! whenever we create a message in the testcase. The other two are fixes for problems reported by Guillaume Quintard. Ferret sup-dump was failing because the query passed to each_id didn''t have any positive terms. The date-ceiling code was broken on 32 bit machines because the maximum signed long is 2**31-1, not 2**31.
William Morgan
2009-Jul-28 16:04 UTC
[sup-talk] [PATCH] explicitly load messages in testcase
Reformatted excerpts from Rich Lane''s message of 2009-07-28:> Sure. The commit "don''t automatically parse header on Message#new" broke > test_message because the message id/etc fields are nil until > load_from_source! is called. This patch just calls load_from_source! > whenever we create a message in the testcase.Got it. Applied, thanks!> The other two are fixes for problems reported by Guillaume Quintard. > Ferret sup-dump was failing because the query passed to each_id didn''t > have any positive terms.Hah.> The date-ceiling code was broken on 32 bit machines because the > maximum signed long is 2**31-1, not 2**31.Ok, both applied. Thanks! -- William <wmorgan-sup at masanjin.net>