This is from the amazing book A Dog's Heart (Собачье сердце).
There is an equally amazing movie (https://www.youtube.com/watch?v=whHySar4EoY), but I am not sure if there is a version with English subtitles. For me it's one of the best Soviet movies. To be fair it was created near the end of the USSR—in 1988. The novel itself was officially published for the first time only in 1987.