| 
									
										
										
										
											2020-10-10 17:53:31 +02:00
										 |  |  | # typed: strict | 
					
						
							| 
									
										
										
										
											2020-09-20 05:57:37 +02:00
										 |  |  | # frozen_string_literal: true | 
					
						
							| 
									
										
										
										
											2020-06-14 11:40:07 +05:30
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-09-10 21:21:05 +01:00
										 |  |  | # This should not be made a constant or Tapioca will think it is part of a gem. | 
					
						
							|  |  |  | dependency_require_map = { | 
					
						
							|  |  |  |   "activesupport" => "active_support", | 
					
						
							|  |  |  |   "ruby-macho"    => "macho", | 
					
						
							|  |  |  | }.freeze | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-05-28 04:07:23 +01:00
										 |  |  | # Don't start coverage tracking automatically | 
					
						
							|  |  |  | ENV["SIMPLECOV_NO_DEFAULTS"] = "1" | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-11-04 05:42:42 +00:00
										 |  |  | # Freeze lockfile | 
					
						
							|  |  |  | Bundler.settings.set_command_option(:frozen, "1") | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | definition = Bundler.definition | 
					
						
							|  |  |  | definition.resolve.for(definition.current_dependencies).each do |spec| | 
					
						
							| 
									
										
										
										
											2021-09-10 21:21:05 +01:00
										 |  |  |   name = spec.name | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-05-28 04:07:02 +01:00
										 |  |  |   # These sorbet gems do not contain any library files | 
					
						
							| 
									
										
										
										
											2021-09-10 21:21:05 +01:00
										 |  |  |   next if name == "sorbet" | 
					
						
							|  |  |  |   next if name == "sorbet-static" | 
					
						
							| 
									
										
										
										
											2022-05-28 04:07:02 +01:00
										 |  |  |   next if name == "sorbet-static-and-runtime" | 
					
						
							| 
									
										
										
										
											2021-09-10 21:21:05 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  |   name = dependency_require_map[name] if dependency_require_map.key?(name) | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   require name | 
					
						
							|  |  |  | rescue LoadError | 
					
						
							|  |  |  |   raise unless name.include?("-") | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   name = name.tr("-", "/") | 
					
						
							|  |  |  |   require name | 
					
						
							|  |  |  | end |