"The force is strong with this one" is apparently a trope and its meaning has already been discussed in Science Fiction & Fantasy SE. The Star Wars franchise started in 1977, but the ability to sense somebody else's powers is also an element in Ursula Le Guin's Earthsea cycle, the first novel of which was published in 1968, almost a decade before Star Wars. In Earthsea, someone with magic powers (including witches) can sense whether someone else also has these abilities, even when they are underdeveloped. However, an untrained person who has this gift does not seem to have this ability.
Robert Heinlein's novella Magic, Inc. (1940) has a "witch smeller", but I am not sure this person has any magic or supernatural abilities similar to that of a witch. So it may not be an example of what I am looking for. All the other works listed in the article Supernatural Sensitivity in the All The Tropes Wiki are more recent than Le Guin's first Eathsea stories.
I don't know if Ursula Le Guin invented this trope; I assume it is older. So where does it come from? In other words, what is the oldest work of literature that use this trope?