mms2r 1.1.4 → 1.1.5

Sign up to get free protection for your applications and to get access to all the features.
data/History.txt CHANGED
@@ -1,3 +1,10 @@
1
+ == 1.1.5 / 2007-08-11 (Mustakrakish, the Lake Troll)
2
+
3
+ * AT&T => mms.att.net not clearing out default "multimedia message"
4
+ subject to nil (Will Jessup)
5
+ * Ignore case on default subject for all carriers in
6
+ corresponding conf/mms2r_XXX_media_subject.yml
7
+
1
8
  == 1.1.4 / 2007-08-07 (Dr. Rockso)
2
9
 
3
10
  * AT&T => mms.att.net support (thanks Mike Chen and Dave Myron)
@@ -1,3 +1,3 @@
1
1
  ---
2
- - !ruby/regexp /^Multimedia message$/
2
+ - !ruby/regexp /^Multimedia message$/i
3
3
 
@@ -1,3 +1,3 @@
1
1
  ---
2
- - !ruby/regexp /^\(no subject\)$/
2
+ - !ruby/regexp /^\(no subject\)$/i
3
3
 
@@ -1,3 +1,3 @@
1
1
  ---
2
- - !ruby/regexp /^Multimedia message$/
2
+ - !ruby/regexp /^Multimedia message$/i
3
3
 
@@ -1,3 +1,3 @@
1
1
  ---
2
- - !ruby/regexp /^You have new Picture Mail!$/
2
+ - !ruby/regexp /^You have new Picture Mail!$/i
3
3
 
data/lib/mms2r.rb CHANGED
@@ -61,7 +61,7 @@ module MMS2R
61
61
  ##
62
62
  # MMS2R Library version
63
63
 
64
- VERSION = '1.1.4'
64
+ VERSION = '1.1.5'
65
65
 
66
66
  end
67
67
 
@@ -33,4 +33,22 @@ class MMS2R::ATTMediaTest < Test::Unit::TestCase
33
33
  assert_file_size(mms.media['image/jpeg'][0], 337)
34
34
  mms.purge
35
35
  end
36
+
37
+ def test_subject
38
+ mail = TMail::Mail.parse(load_mail('att-image-02.mail').join)
39
+ mms = MMS2R::Media.create(mail)
40
+ assert_equal(MMS2R::ATTMedia, mms.class, "expected a #{MMS2R::ATTMedia} and received a #{mms.class}")
41
+ mms.process
42
+
43
+ assert(mms.media.size == 1)
44
+ assert_nil(mms.media['text/plain'])
45
+ assert_nil(mms.media['text/html'])
46
+ assert_not_nil(mms.media['image/jpeg'][0])
47
+ assert_match(/Photo_12.jpg$/, mms.media['image/jpeg'][0])
48
+
49
+ assert_file_size(mms.media['image/jpeg'][0], 337)
50
+
51
+ assert_nil mms.get_subject
52
+ mms.purge
53
+ end
36
54
  end
metadata CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.4
3
3
  specification_version: 1
4
4
  name: mms2r
5
5
  version: !ruby/object:Gem::Version
6
- version: 1.1.4
7
- date: 2007-08-07 00:00:00 -07:00
6
+ version: 1.1.5
7
+ date: 2007-08-11 00:00:00 -07:00
8
8
  summary: Extract user media from MMS (and not carrier cruft)
9
9
  require_paths:
10
10
  - lib