Thanks for your reply, I did it using the method below.
share with everyone.

# The condition is met if $Context.ConditionIsMet is set to $True.
$UserName = '%sAMAccountName%'
$Password = '%param-P01%'
Function Test-ADAuthentication {
param(
$username,
$password)
(New-Object DirectoryServices.DirectoryEntry "",$username,$password).psbase.name -ne $null
}
$condition = Test-ADAuthentication -username $UserName -password $password
if ( $condition)
{
$Context.ConditionIsMet = $True
}
