nixos/tests/bootspec: assert for boot.json rather than bootspec/boot.json
This commit is contained in:
		
							parent
							
								
									58f4c3944d
								
							
						
					
					
						commit
						e3a41f3fec
					
				| @ -108,9 +108,9 @@ in | |||||||
|       machine.start() |       machine.start() | ||||||
|       machine.wait_for_unit("multi-user.target") |       machine.wait_for_unit("multi-user.target") | ||||||
| 
 | 
 | ||||||
|       machine.succeed("test -e /run/current-system/bootspec/boot.json") |       machine.succeed("test -e /run/current-system/boot.json") | ||||||
| 
 | 
 | ||||||
|       bootspec = json.loads(machine.succeed("jq -r '.v1' /run/current-system/bootspec/boot.json")) |       bootspec = json.loads(machine.succeed("jq -r '.v1' /run/current-system/boot.json")) | ||||||
| 
 | 
 | ||||||
|       assert all(key in bootspec for key in ('initrd', 'initrdSecrets')), "Bootspec should contain initrd or initrdSecrets field when initrd is enabled" |       assert all(key in bootspec for key in ('initrd', 'initrdSecrets')), "Bootspec should contain initrd or initrdSecrets field when initrd is enabled" | ||||||
|     ''; |     ''; | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Raito Bezarius
						Raito Bezarius