For 90-degree (clockwise and anti-clockwise) rotations you can verify the width and height values have switched. Obviously this won't help for square images (unlikely for photos).
For 180-degree rotations, verify the width and height haven't changed. Further, you could take some measure of some top rows and bottom rows. For example, convert to greyscale and count the darkness (or keep as colour and count the blueness). Allowing for some variation, the darker side should now be on the other side. You could also measure some left and right rows. Similarly this could be applied for 90-degree rotations.