Oh wow... I am so sorry that you & your family are facing such a difficult decision. Those who know me well on this site know that I am a breeder & very passionate about my dogs, & pets in general. I have been on the opposite side of the fence - I have family members that are upset with me because my husband & I have chosen on more than one occasion to have a costly surgery/procedure done on our dogs to save their life. Because they would not spend as much $$, they think we wasted ours.
But cost is subjective - what is a struggle for you, someone else could easily afford, and another person couldn't even begin to contemplate. Bottom line, however, is that you & your family have the financial means to give your dog a wonderful, cared-for life, but not unlimited resources to provide ongoing, intensive care for a chronic condition. There is no shame in that. I don't think people should be independently wealthy as a criteria to have the joy & love of a companion in their lives.
One of the unfortunate lessons I am learning in Pharmacy school is that there are people & families who do NOT get the medication they need, because of cost. Because they don't have insurance, or the insurance doesn't cover the medication, or the out of pocket costs are more than they can afford. But no one is telling people they shouldn't have children because one day they might get sick & you won't be able to afford their care. You need to make the decision that is best for you, your family, the dog & the big picture.
One thing I have noticed over the years is that with better technology available, the costs of caring for our pets is increasing as well. There are things we can do today that we couldn't do for our pets 25 years ago, & the decisions to let our beloved go weren't looked at with the scorn they are today. 25 years ago, people didn't pay hundreds of dollars for an x-ray & labs (non emergency), now that is standard, & most emergency visits don't come with a price tag below $1000.
Just because it's available, doesn't mean we can, or even should, based on the quality of life the pet may face afterwards. I am not a proponent of the excessive life-saving efforts on pets who are in near-death conditions (burns, massive trauma, etc.) costing tens of thousands, & months of pain.
Pet insurance is available, but if you didn't get it when your dog was a puppy, they are very tight on the pre-existing & exclusion clauses. And the coverage that they offer is not always comprehensive to the conditions your dog may develop. Certainly something to look into for any pet owner, but likely no longer helpful for your situation.
Talk with your vet about all the treatment options. Look into whether there might be lower cost options, or treatments that might be covered through programs. And I will pray that the test results come back with better results than you are preparing yourselves for.
If you are facing the worst, & you need to say your goodbyes, do so knowing that you gave your dog the best 5 years it could ever want, and you did it with love in your heart. That's all they ask for. Peace to you. T.