You would need to use project workflow to accomplish this.
You would also need to ensure that the status field is not being versioned (customization - project entities). Otherwise, the status field would not be able to be changed until after the test is checked out.
You could also create a user-defined field that is not versioned to use instead of status if you wish.
The workflow for this would be placed under the Common Script - ActionCanExecute section:
Example:
Function ActionCanExecute(ActionName)
If ActionName = ''VersionService.CheckOut'' Then
Test_Fields.Field(''TS_STATUS'').Value = ''Passed''
End If
ActionCanExecute = True
End Function