جدا کردن امتیاز از عدد
Sun Aug 06 2023 08:09:47 GMT+0000 (Coordinated Universal Time)
Saved by
@mehran
LOGGER.info("برسی امتیاز");
String test1=driver.findElement(By.id("ir.mci.ecareapp:id/loyalty_score_game_tv_club_games_activity")).getText();
String numbers = test1.replaceAll("[^0-9]", "");
//int sum = Integer.parseInt(numbers) - 100;
int ScoreGame = Integer.parseInt(test1);
System.out.println(ScoreGame);
LOGGER.info("امتیاز کاربر"+ScoreGame);
if (ScoreGame <= 0) {
LOGGER.error("Test failed ");
Assert.fail("Test failed ");
}
content_copyCOPY
Comments