Etymonline gives the etymology of testify as
…from testis "a witness".. + root of facere "to make"… Biblical sense of "openly profess one's faith and devotion" is attested from 1520s. Related: Testified; testifying; testification. (also, testament, intestate, etc.)
In Biblical times, to swear a most sacred oath, the swearer made his oath by holding on to the oath-giver's genitals.
Abraham… said to the senior servant in his household…Put your hand under my thigh. I want you to swear by the Lord… that you will not get a wife for my son from the daughters of the Canaanites… So the servant put his hand under the thigh of his master Abraham and swore… (Gen. 24)
and
When the time drew near for Israel (Jacob) to die, he called… Joseph and said to him, “…put your hand under my thigh and promise that you will… not bury me in Egypt…" Then Joseph swore to him, and Israel worshiped as he leaned on the top of his staff. (Gen. 47)
Rabbi Shlomo Itzhaki (aka Rashi) explains in his commentary:
Since one (a Jew) who swears must take with his hand an article related to a mitzvah… and circumcision was his [Abraham's] first mitzvah, and he had fulfilled it with pain, [Abraham's circumcised penis] was dear to him; so he took it. (bracketed expansions mine)
Others interpret (reason?) that this oath was sworn by holding the oath-giver's testicles.
The Latin word for "witness, one who attests" is testis, as well as testicles (from Latin testiculus, diminutive of testis). The Greek for spermaria is similarly derived.
So, how did testify, testimony, testament, protest, detest, contest, even Old and New Testament diverge so wildly from it's origins, to swear while holding someone's penis or testicles? Why don't we swear by our balls, soft bits, tallywags, twiddle-diddles, goolies, trinkets, bollocks, nuts, or cojones?
Was there ever a time when such little things didn't make such big promises?
Best Answer
Testo an Italian word derives from the Latin term, textum (text), which in turn originated from the verb texĕre, which means to weave.
Treccani, the Italian online dictionary and encyclopedia par excellence says:
Roughly translated, the word testo is used when referring to the classics i.e. classic literature, and sacred works or volumes.
The verb, testify, (In Italian testimoniare) derives from the noun, testimony, its Latin form testimonium which the OP rightly affirmed derives from testis and its plural form teste.
From Dictionary.com
testis
Looking at the word teste, which means
alsowitness in Italian, according to Treccani it derived originally from the Latin term, tristis (sad, sorrowful, disagreeable or foul smelling) which later evolved into terstis, meaning third party.So far I haven't find any solid evidence that suggests testament, testimony, testify, are directly related to testes/testicles. I'm more inclined to believe that the root word is textum meaning text or teste (witness), therefore the tradition of swearing an oath by placing one's hand on the Bible rather than on one's testicles, makes sense. If this needs reminding, Christians are not required to be circumcised, so there is no guarantee the judge would be circumcised. See David M's answer as to why it is relevant.
One more thing to consider, would women really have been asked to place their hands on the judge's genitals before a court of law? Back when?
Edit
From the Wikipedia article entitled Sexuality in Ancient Rome
link 186 informs
I had to look up hapax because I don't think I have ever come across this word before. A hapax legomenon is a word that occurs only once within a context, either in the written record of an entire language, in the works of an author, or in a single text.
A Slate article, Where Did We Get Our Oath? debunks the urban legend, as it claims, of ancient Romans who vowed to tell the truth by grabbing hold of their testicles or as I found in one recount; of two male witnesses who would hold each other's testicles when taking an oathGames Primates Play, I'm inclined to think this version is rather fanciful and at this point we really need an expert in Ancient History.
Witness (Testimonio 1/Testimone 2/Teste 3)
Until the 16th century the Italian for witness used to be testimonio but today that has been superceded by testimone and teste. A brief history of the word, testimonianza, written in Italian, is provided by Treccani. Testimonianza in English is deposition (Law) Sworn testimony recorded for use in court at a later date.
In his book, AIDS, Bearing Witness, and the Queer Moving Image, Roger Hallas provides this clear explanation.
Consequently, it appears that the word, testify, and all its derivatives come from the Latin term, terstis (third party or person) which Treccani also confirms.