"brief examination by a teacher of a student or class on some subject," originally oral, 1852, colloquial, of uncertain origin.
Perhaps from quiz (v.), which might be from Latin. Or from slang quiz "odd person, person or thing deemed ridiculous" (1782, itself perhaps originally university slang), via the notion of "schoolboy prank or joke at the expense of a person deemed a quiz," a noun sense attested frequently 1840s, but quiz (n.) in the sense of "puzzling question, one designed to make one ridiculous" seems to not be attested before 1807. More than one etymological thread might be involved here. The word itself seems to have confused literary English from the beginning.
A Quiz, in the common acceptation of the word, signifies one who thinks, speaks, or acts differently from the rest of the world in general. But, as manners and opinions are as various as mankind, it will be difficult to say who shall be termed a Quiz, and who shall not: each person indiscriminately applying the name of Quiz to every one who differs from himself .... [The London Magazine, November 1783]
The word Quiz is a sort of a kind of a word
That people apply to some being absurd;
One who seems, as t'were oddly your fancy to strike
In a sort of a fashion you somehow don't like
A mixture of odd, and of queer, and all that
Which one hates, just, you know, as some folks hate a cat;
A comical, whimsical, strange, droll — that is,
You know what I mean; 'tis — in short, — 'tis a quiz!
[from "Etymology of Quiz," Charles Dibdin, 1842]
According to OED, the anecdote that credits this word to a bet by the Dublin theater-manager Daly or Daley that he could coin a word is regarded by authorities as "doubtful" and the first record of it appears to be in 1836 (in Smart's "Walker Remodelled"; the story is omitted in the edition of 1840). The medical school quiz class is attested from 1853. "The object of the Quiz will be to take the students over the ground of the different lectures in a thorough review, by a system of close questioning, so as to make them familiar with the subject-matter of the lectures to a degree not to be obtained in any other way" [Missouri Clinical Record, 1875].
"to question," 1847, quies, "examine a student orally," perhaps from Latin qui es? "who are you?," the first question in oral exams in Latin in old-time grammar schools.
The spelling quiz is recorded by 1886, though it was in use as a noun spelling from 1854, perhaps in this case from the slang word quiz "odd person" (1782, source of quizzical); an earlier verb from that sense was quizify "turn (someone) into a quiz" (1834). Also compare quiz (n.).
Quiz in the verbal sense of "make sport of by means of puzzling questions" is attested by 1796, from the noun, and compare quizzing glass "monocular eyeglass," attested by 1802, and quisby "queer, not quite right; bankrupt" (slang from 1807). Whether of separate origin or not, the verb and noun have grown together in English.
The sense of "scrutinize suspiciously" is by 1906. Quiz-master is by 1866 in the schoolroom sense; by 1949 in reference to a radio quiz show host. Also from the era of radio quiz shows comes quizzee (n.), 1940, and quiz-kid.