Fix tests to proper condition