I'm facing an issue where the below function is getting skipped during debugging, regardless of the scenario. I'm at a loss as to why this is happening as nothing is being thrown out of the catch block. Upon debugging, I find myself immediately reaching the last line after the catch block. Any assistance would be greatly appreciated.
public async Function(licence:string,stepDescription) {
try{
let count:number = await this.doctorsLicenceNumbers.count();
let checked:boolean = false;
let doctorRefernceFromWeb;
for(let i=0; i < count; i++) {
doctorRefernceFromWeb = await this.doctorsLicenceNumbers.get(i).getText();
if (doctorRefernceFromWeb == licence) {
checked=true;
await this.doctorsReferncesCheckBoxes3.get(i).click();
}
};
}
}catch(e){
console.log("function failed error is: " +e);
}
}