mirror of
				https://github.com/ruby/ruby.git
				synced 2022-11-09 12:17:21 -05:00 
			
		
		
		
	* lib/net/smtp.rb (Net::SMTP#critical): Always return a
Net::SMTP::Response. Patch by Pawel Veselov. [ruby-trunk - Bug #9125] * test/net/smtp/test_smtp.rb: Test for the above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43954 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
		
							parent
							
								
									673efdceef
								
							
						
					
					
						commit
						34e57abf23
					
				
					 3 changed files with 21 additions and 1 deletions
				
			
		|  | @ -21,6 +21,19 @@ module Net | |||
|       end | ||||
|     end | ||||
| 
 | ||||
|     def test_critical | ||||
|       smtp = Net::SMTP.new 'localhost', 25 | ||||
| 
 | ||||
|       assert_raises RuntimeError do | ||||
|         smtp.send :critical do | ||||
|           raise 'fail on purpose' | ||||
|         end | ||||
|       end | ||||
| 
 | ||||
|       assert_kind_of Net::SMTP::Response, smtp.send(:critical), | ||||
|                      '[Bug #9125]' | ||||
|     end | ||||
| 
 | ||||
|     def test_esmtp | ||||
|       smtp = Net::SMTP.new 'localhost', 25 | ||||
|       assert smtp.esmtp | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 drbrain
						drbrain