| 
									
										
										
										
											2020-10-10 14:16:11 +02:00
										 |  |  | # typed: false | 
					
						
							| 
									
										
										
										
											2019-04-19 15:38:03 +09:00
										 |  |  | # frozen_string_literal: true | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2019-03-27 11:49:56 +00:00
										 |  |  | require "cmd/shared_examples/args_parse" | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-02-01 16:14:25 -05:00
										 |  |  | describe "brew tap-new" do | 
					
						
							| 
									
										
										
										
											2019-03-27 11:49:56 +00:00
										 |  |  |   it_behaves_like "parseable arguments" | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-02-01 16:14:25 -05:00
										 |  |  |   it "initializes a new tap with a README file and GitHub Actions CI", :integration_test do | 
					
						
							| 
									
										
										
										
											2021-04-02 14:58:31 +05:30
										 |  |  |     # To ensure that Utils::Git.setup_gpg! doesn't raise an error | 
					
						
							|  |  |  |     setup_test_formula "gnupg" | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-02-23 06:04:40 +01:00
										 |  |  |     expect { brew "tap-new", "homebrew/foo", "--verbose" } | 
					
						
							|  |  |  |       .to be_a_success | 
					
						
							| 
									
										
										
										
											2019-03-23 12:41:35 +00:00
										 |  |  |       .and output(%r{homebrew/foo}).to_stdout | 
					
						
							| 
									
										
										
										
											2017-02-23 06:04:40 +01:00
										 |  |  |       .and not_to_output.to_stderr | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |     expect(HOMEBREW_LIBRARY/"Taps/homebrew/homebrew-foo/README.md").to exist | 
					
						
							| 
									
										
										
										
											2020-08-04 11:57:39 +01:00
										 |  |  |     expect(HOMEBREW_LIBRARY/"Taps/homebrew/homebrew-foo/.github/workflows/tests.yml").to exist | 
					
						
							| 
									
										
										
										
											2017-02-23 06:04:40 +01:00
										 |  |  |   end | 
					
						
							|  |  |  | end |