A test can't be done in a lab on bloods but most of the time you can usually see the signs simply by observation and just talking to the person.
I say the real problem is that it's hard to treat.
When you see a close family member or friend suffering, you can't force them to go the doctors, where depression would certainly be diagnosed, and many often just don't go.
The standard set of medication for depression usually takes a couple of weeks to kick in. It's common to see symptoms worsen before they get better during this timeframe. It's gut wrenching to watch if you have personal experience with it.
Effective therapies require effort from the sufferer. If you're feeling really low, it's hard to the put the effort into anything - drops in personal hygiene standards are not rare.
It sucks we don't have a test for it like we have for physical disease but I think a bigger problem is treatment, which is done in a "see what works" manner if the first line of defence doesn't work, which is really damaging when you consider the above.