Selenium IDE에서 새로운 기능이므로 줄 바꿈이있는 값을 assertText에 써야합니다. 예 : assertText에assertText Selenium IDE에서 줄 바꿈이있는 메시지
실제 메시지 :
안녕하세요
세계
store | Hello <br/> World | txtValue
assertText | id=label | ${txtValue}
도와주세요.
Selenium IDE에서 새로운 기능이므로 줄 바꿈이있는 값을 assertText에 써야합니다. 예 : assertText에assertText Selenium IDE에서 줄 바꿈이있는 메시지
실제 메시지 :
안녕하세요
세계
store | Hello <br/> World | txtValue
assertText | id=label | ${txtValue}
도와주세요.
id=label
을 변수에 전달하고 줄 바꿈을 제거한 다음 변수에 대한 어설 션을 실행하십시오.
스토어 예상 텍스트 :
이store | Hello World | txtValue
스토어 페이지 텍스트 : 페이지 텍스트에서
storeText | xpath=(//*[@id=label]) | labelValue
제거 줄 바꿈 :
echo | javascript{storedVars.labelValue = storedVars.labelValue.replace(/(\r\n|\n|\r)/gm,"")} |
가 어설 당신의 예상 텍스트 = 페이지 텍스트 :
assertExpression | javascript{storedVars.txtValue==storedVars.labelValue} | true
패턴 매칭 다음은 Selenium IDE 2.5.0
regexp:Hello\s+World
당신이 봤어'에 나를 위해 일한 \ n'? – VolkerK