| 
									
										
										
										
											2017-03-05 19:26:56 +01:00
										 |  |  | describe Hbc::Container::Dmg, :cask do | 
					
						
							| 
									
										
										
										
											2017-02-09 03:31:55 +01:00
										 |  |  |   describe "#mount!" do | 
					
						
							| 
									
										
										
										
											2016-08-18 22:11:42 +03:00
										 |  |  |     it "does not store nil mounts for dmgs with extra data" do | 
					
						
							| 
									
										
										
										
											2016-12-06 16:36:34 +01:00
										 |  |  |       transmission = Hbc::CaskLoader.load_from_file(TEST_FIXTURE_DIR/"cask/Casks/local-transmission.rb") | 
					
						
							| 
									
										
										
										
											2016-08-18 22:11:42 +03:00
										 |  |  | 
 | 
					
						
							|  |  |  |       dmg = Hbc::Container::Dmg.new( | 
					
						
							|  |  |  |         transmission, | 
					
						
							|  |  |  |         Pathname(transmission.url.path), | 
					
						
							| 
									
										
										
										
											2017-02-12 15:06:54 +00:00
										 |  |  |         Hbc::SystemCommand, | 
					
						
							| 
									
										
										
										
											2016-08-18 22:11:42 +03:00
										 |  |  |       ) | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |       begin | 
					
						
							|  |  |  |         dmg.mount! | 
					
						
							| 
									
										
										
										
											2017-02-09 03:31:55 +01:00
										 |  |  |         expect(dmg.mounts).not_to include nil | 
					
						
							| 
									
										
										
										
											2016-08-18 22:11:42 +03:00
										 |  |  |       ensure | 
					
						
							|  |  |  |         dmg.eject! | 
					
						
							|  |  |  |       end | 
					
						
							|  |  |  |     end | 
					
						
							|  |  |  |   end | 
					
						
							|  |  |  | end |