וַיֹּ֤אמֶר לָהֶם֙ יוֹסֵ֔ף מָֽה־הַמַּעֲשֶׂ֥ה הַזֶּ֖ה אֲשֶׁ֣ר עֲשִׂיתֶ֑ם הֲל֣וֹא יְדַעְתֶּ֔ם כִּֽי־נַחֵ֧שׁ יְנַחֵ֛שׁ אִ֖ישׁ אֲשֶׁ֥ר כָּמֹֽנִי׃
Yosef said to them, “What is this deed that you have done? Do you not know that a man like me practices divination?”
Midrash Tanchuma, Miketz 10:11. The Midrash directly interprets Yosef’s words in this passuk as part of his explanation of the staged test.
The Midrash has Yosef explain that the youth was taken in order to use the goblet for divination and discover where his brother was. Thus the accusation is presented as part of the constructed test rather than as a spontaneous charge.
What Is Learned: The passuk exposes the stated logic Yosef uses for the goblet, while the Midrash places that statement inside the larger strategy that brings Yehudah to respond.