You're not getting a 100% guarantee that your Mac will work either. I'm sure it's happened before where a Mac was shipped defective, or shortly after messed up. But I can tell you this; my motherboard went through a 168 hour burn test before it was shipped to the retailer, which pretty much guarantees a working mobo.
But let's say that one of my parts does crap out. Ok, I'm on my own. But I know my way around hardware real well so it won't take me long to figure out. Let's say it's my GPU that fizzled out. No biggie; I get an RMA, done. Some manufacturers will even send you a replacement part with another box to ship back the defective part. Even if they didn't, I could always resort to the oboard GPU or use something else off the shelf.
With Apple the story is very different. And I know firsthand because I had the GPU in my 2011 MBP fry on me. I handed Apple my MacBook Pro for diagnosis, the GPU was in fact dead, and the repair cost me $600 CAD. But not just the GPU, it needed a whole new motherboard as its soldered. I was without a computer for 3 weeks as they needed a replacement mobo shipped out to me. Now, your immediate argument is going to be 'but thats a laptop'. Sure, it is. But the GPU is also soldered on the iMac. And the GPUs on the Mac Pros are proprietary. And a whack load of other components are soldered on the Macs as well, if not proprietary in other areas.
So now while you have the comfort of Apple holding your hand throughout the process, you also have the pleasure of waiting ages for things to get fixed.... at a price premium.
Sure, but that's not what we're comparing it to. You have a 'whopping' THREE choices for a desktop computer from Apple; Mac Mini, iMac and Mac Pro. That's it. In the Windows world you've got a plethora of options, so while you COULD spend as much as you would on a PC as you would on an Apple, you are NOT going to run into the same bottlenecks.