Aside from selling hackintosh computers I don’t think I’ve ever heard of Apple going after someone for running macOS on third party hardware or running it virtualized. If you try to make a business out of it they will come after you but they are going after developers.
Nowadays something like BrowserStack feels like a requirement anyways since I’ll never have all the devices I need to test.
Safari can only be run on Apple machines manufactured by Apple.