[lldb/test] Fix a fragile assumption in TestTypeGetModule
the binary can contain more than three compile units if the compiler support files (crtbegin/end, etc.) come with their own debug info.
This commit is contained in:
		
							parent
							
								
									cc96a82291
								
							
						
					
					
						commit
						e3645fdff4
					
				| 
						 | 
					@ -67,7 +67,7 @@ class TestTypeGetModule(TestBase):
 | 
				
			||||||
        exe_module = self.find_module(target, 'a.out')
 | 
					        exe_module = self.find_module(target, 'a.out')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        num_comp_units = exe_module.GetNumCompileUnits()
 | 
					        num_comp_units = exe_module.GetNumCompileUnits()
 | 
				
			||||||
        self.assertEqual(num_comp_units, 3)
 | 
					        self.assertGreaterEqual(num_comp_units, 3)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        comp_unit = self.find_comp_unit(exe_module, 'compile_unit1.c')
 | 
					        comp_unit = self.find_comp_unit(exe_module, 'compile_unit1.c')
 | 
				
			||||||
        cu_type = self.find_type(comp_unit.GetTypes(), 'compile_unit1_type')
 | 
					        cu_type = self.find_type(comp_unit.GetTypes(), 'compile_unit1_type')
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue