Fourier Transform and Delta Function
The textbook is right. A sine wave in the time domain has infinite energy since it continues over an infinite amount of time. When you transform into the Frequency domain all this energy is concentrated on a single (or two) frequency. Hence the value there is indeed infinite. 

Of course these are all theoretical considerations. In the real world, ideal sine waves do not exist since they all have a beginning and an end.