It is correct that you won't normally have to show your passport (I am saying "normally" because every now and again passport controls get temporarily reinstated at certain borders, for example, if a country is hosting a major international summit or a major sporting event).
However, you may (or may not) get woken up by a ticket inspector - this depends on whether or not there is a crew change at the border.
To find out how long into the trip you may get disturbed look up your train at
www.bahn.de and select the "show intermediate stops" option (I don't know if it's called "intermediate stops" or something slightly different as I use the German version where it is called "Zwischenhalte"). Any ticket inspections will take place either just before or just after the first stop on the Dutch side of the border.