As Salim said, WSN is part of IoT, but IoT is not necessarily WSN.
Sensor networks are typically involved with data collection applications, where the data is processed on the back-end (although there may also be actuation in response to this data).
IoT encompasses WSNs, but it is also the idea that these sensor networks will also have some form of external connectivity to larger networks (including but not necessarily the internet). IoT also includes Cyber Physical Systems, and concepts such as Home Automations, Smart Grids, Smart Cities etc. etc.