A 29-year-old man who might be at risk of falling victim to a form of hereditary cancer has won an "unprecedented" court fight in the UK over DNA testing with a woman he suspects is his grandmother.
David Spencer thought that his father was William Anderson - who died nearly four years ago, a court heard.
He wanted a judge to rule that a stored DNA sample taken from Mr Anderson for medical purposes before death should be tested so that he could establish his paternity.
Mr Anderson's mother, Valerie Anderson, was against the idea.
But Mr Justice Peter Jackson has ruled in Mr Spencer's favour after analysing evidence at a hearing in the Family Division of the High Court in Manchester - and said testing should take place.
Detail has emerged in a written ruling by Mr Justice Jackson published on a legal website. He named people involved but gave no indication of where they lived.
The judge said Mr Spencer's application was "apparently unprecedented" in England and Wales. He outlined family histories which had led to litigation in his ruling.
Mr Spencer said his mother, Carol Spencer, had him told that his father was Mr Anderson. Mrs Spencer had said the relationship ended when she was pregnant.
She had married another man - and he had been registered as Mr Spencer's father.
That marriage had ended and Mrs Spencer had gone on to marry a man called Spencer.
Mr Justice Jackson said Mr Anderson had been diagnosed with a form of cancer a decade ago. He said there was a history of cancer in the Anderson family.
Mr Spencer had said that, following Mr Anderson's death in 2012, Mrs Anderson had contacted him and said he could be at risk.
He had subsequently launched legal action and asked for a DNA testing order.
Mrs Anderson had opposed testing, saying her son had provided a DNA sample during the course of medical treatment and was "entitled to a high expectation of confidentiality".
Mr Justice Jackson ruled in Mr Spencer's favour.
"I have reached the conclusion that scientific testing should take place to seek to establish the paternity of Mr Spencer by using the stored DNA sample of the late Mr Anderson," said the judge.
"The overall evidence here raises the real possibility that Mr Anderson was Mr Spencer's father, he having undeniably been in a relationship with Mr Spencer's mother at the time of conception.
"It is common ground between the parties that there is a significant medical issue that turns on the possibility of a biological relationship between Mr Anderson and Mr Spencer."
The judge added: "Although it is possible that the late Mr Anderson ... might have refused to consent to testing during his lifetime, there is no particular reason to regard that as likely.
"Whether or not he would have welcomed the possibility that he was a father, it may not do justice to his memory to assume that he would have withheld his support from a young man who might have inherited a serious medical condition from him.
"The information, in the form of the DNA sample, is readily available and does not require physically intrusive investigations. In particular, it does not require exhumation, as to which particular considerations would undoubtedly arise."
He said bosses at the hospital where the DNA sample was stored did not object to testing.