Skip to content

Commit

Permalink
clean out cruft sub_type? method
Browse files Browse the repository at this point in the history
  • Loading branch information
monde committed Jul 24, 2008
1 parent 90b2174 commit 3468e16
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
7 changes: 0 additions & 7 deletions lib/mms2r/media.rb
Original file line number Diff line number Diff line change
Expand Up @@ -529,13 +529,6 @@ def self.default_ext(content_type)
ext
end

##
# Determines the sub type of the part's mime-type

def self.sub_type?(part)
/\/([^\/]+)$/.match(part.part_type?)[1]
end

##
# Joins the generic mms2r configuration with the carrier specific
# configuration.
Expand Down
5 changes: 0 additions & 5 deletions test/test_mms2r_media.rb
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,6 @@ def test_default_ext
assert_equal 'test', MMS2R::Media.default_ext('example/test')
end

def test_sub_type
part = stub(:content_type => 'image/jpeg', :part_type? => 'image/jpeg')
assert_equal 'jpeg', MMS2R::Media.sub_type?(part)
end

def test_base_initialize_config_tries_to_open_default_config_yaml
f = File.join(MMS2R::Media.conf_dir, 'mms2r_media.yml')
YAML.expects(:load_file).once.with(f).returns({})
Expand Down

0 comments on commit 3468e16

Please sign in to comment.