For a CI, my best bet would be to save a running snapshot of each OS to test and derive a new instance from there for every job. Also isolate the network bridge from the outside world. The only thing you may have to fix is time synchronization, but your vmm could already be taking care of that.
for newer Windows versions, Microsoft also offers a PE-like customizable image for validation purposes explicitly: https://learn.microsoft.com/en-us/windows-hardware/manufactu...
Oh "Preinstallation Environment" not PE as in the executable header in windows.
That’s nice. Windows drivers have always been a PITA to test.