WP has global $is_iis7
variable, which is filled via following code:
$is_iis7 = $is_IIS && intval( substr( $_SERVER['SERVER_SOFTWARE'], strpos( $_SERVER['SERVER_SOFTWARE'], 'Microsoft-IIS/' ) + 14 ) ) >= 7;
If detection is not working correctly likely something is going wrong with this line, such as server vars not being filled with the info expected.