mirror of
				https://github.com/prometheus/node_exporter.git
				synced 2025-08-20 18:33:52 -07:00 
			
		
		
		
	Add fixture for ppc64le (#785)
* Add support for per-architecture fixtures. * Add output for ppc64le.
This commit is contained in:
		
							parent
							
								
									bc38ffc538
								
							
						
					
					
						commit
						b4d7ba119a
					
				
							
								
								
									
										3313
									
								
								collector/fixtures/e2e-ppc64le-output.txt
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										3313
									
								
								collector/fixtures/e2e-ppc64le-output.txt
									
									
									
									
									
										Normal file
									
								
							
										
											
												File diff suppressed because it is too large
												Load diff
											
										
									
								
							|  | @ -52,6 +52,13 @@ tmpdir=$(mktemp -d /tmp/node_exporter_e2e_test.XXXXXX) | ||||||
| 
 | 
 | ||||||
| skip_re="^(go_|node_exporter_build_info|node_scrape_collector_duration_seconds|process_|node_textfile_mtime)" | skip_re="^(go_|node_exporter_build_info|node_scrape_collector_duration_seconds|process_|node_textfile_mtime)" | ||||||
| 
 | 
 | ||||||
|  | arch="$(uname -m)" | ||||||
|  | 
 | ||||||
|  | case "${arch}" in | ||||||
|  |   ppc64le) fixture='collector/fixtures/e2e-ppc64le-output.txt' ;; | ||||||
|  |   *) fixture='collector/fixtures/e2e-output.txt' ;; | ||||||
|  | esac | ||||||
|  | 
 | ||||||
| keep=0; update=0; verbose=0 | keep=0; update=0; verbose=0 | ||||||
| while getopts 'hkuv' opt | while getopts 'hkuv' opt | ||||||
| do | do | ||||||
|  | @ -108,7 +115,7 @@ EOF | ||||||
| 
 | 
 | ||||||
|   if [ ${update} -ne 0 ] |   if [ ${update} -ne 0 ] | ||||||
|   then |   then | ||||||
|     cp "${tmpdir}/e2e-output.txt" "collector/fixtures/e2e-output.txt" |     cp "${tmpdir}/e2e-output.txt" "${fixture}" | ||||||
|   fi |   fi | ||||||
| 
 | 
 | ||||||
|   if [ ${keep} -eq 0 ] |   if [ ${keep} -eq 0 ] | ||||||
|  | @ -141,5 +148,5 @@ sleep 1 | ||||||
| get "127.0.0.1:${port}/metrics" | grep -E -v "${skip_re}" > "${tmpdir}/e2e-output.txt" | get "127.0.0.1:${port}/metrics" | grep -E -v "${skip_re}" > "${tmpdir}/e2e-output.txt" | ||||||
| 
 | 
 | ||||||
| diff -u \ | diff -u \ | ||||||
|   "collector/fixtures/e2e-output.txt" \ |   "${fixture}" \ | ||||||
|   "${tmpdir}/e2e-output.txt" |   "${tmpdir}/e2e-output.txt" | ||||||
|  |  | ||||||
		Loading…
	
		Reference in a new issue