The Prophet (ﷺ) was cupped while he was fasting.
Sahih al-Bukhari Book 76, Hadith 16