jeudi 23 janvier 2020

how to find error of Unable to find the element located by 'By.xpath:

Unable to find the element located by 'By.xpath: id("product_attribute_2")[count(. | //select[@name = 'product_attribute_2' and @id = 'product_attribute_2' and (text() = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ' or . = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ')]) = count(//select[@name = 'product_attribute_2' and @id = 'product_attribute_2' and (text() = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ' or . = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ')])]'. Please recheck the objects properties to make sure the desired element is located. 01-24-2020 10:57:38 AM selectOptionByLabel(findTestObject("Search Relevancy/8 GB computer -it should give all product contain 8 GB computer/Page_Your store. Build your own com/select_2 GB"), "8GB [+$60.00]", false)

Elapsed time: 46.156s

Unable to select option by label '8GB [+$60.00]' of object 'Object Repository/Search Relevancy/8 GB computer -it should give all product contain 8 GB computer/Page_Your store. Build your own com/select_2 GB' (Root cause: com.kms.katalon.core.exception.StepFailedException: Unable to select option by label '8GB [+$60.00]' of object 'Object Repository/Search Relevancy/8 GB computer -it should give all product contain 8 GB computer/Page_Your store. Build your own com/select_2 GB' at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed(WebUIKeywordMain.groovy:64) at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:26) at com.kms.katalon.core.webui.keyword.builtin.SelectOptionByLabelKeyword.selectOptionByLabel(SelectOptionByLabelKeyword.groovy:98) at com.kms.katalon.core.webui.keyword.builtin.SelectOptionByLabelKeyword.execute(SelectOptionByLabelKeyword.groovy:71) at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:72) at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.selectOptionByLabel(WebUiBuiltInKeywords.groovy:1200) at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$selectOptionByLabel$4.call(Unknown Source) at 001. 8 GB computer -it should give all product contain 8 GB computer.run(001. 8 GB computer -it should give all product contain 8 GB computer:29) at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194) at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119) at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337) at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328) at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307) at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299) at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233) at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:114) at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:105) at com.kms.katalon.core.main.TestCaseMain$runTestCase$0.call(Unknown Source) at TempTestCase1579843640370.run(TempTestCase1579843640370.groovy:23) Caused by: com.kms.katalon.core.webui.exception.WebElementNotFoundException: Web element with id: 'Object Repository/Search Relevancy/8 GB computer -it should give all product contain 8 GB computer/Page_Your store. Build your own com/select_2 GB' located by 'By.xpath: id("product_attribute_2")[count(. | //select[@name = 'product_attribute_2' and @id = 'product_attribute_2' and (text() = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ' or . = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ')]) = count(//select[@name = 'product_attribute_2' and @id = 'product_attribute_2' and (text() = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ' or . = ' 2 GB 4GB [+$20.00] 8GB [+$60.00] ')])]' not found at com.kms.katalon.core.webui.common.WebUiCommonHelper.findWebElement(WebUiCommonHelper.java:1154) at com.kms.katalon.core.webui.keyword.internal.WebUIAbstractKeyword.findWebElement(WebUIAbstractKeyword.groovy:27) at com.kms.katalon.core.webui.keyword.internal.WebUIAbstractKeyword.findWebElement(WebUIAbstractKeyword.groovy:26) at com.kms.katalon.core.webui.keyword.builtin.SelectOptionByLabelKeyword$_selectOptionByLabel_closure1.doCall(SelectOptionByLabelKeyword.groovy:86) at com.kms.katalon.core.webui.keyword.builtin.SelectOptionByLabelKeyword$_selectOptionByLabel_closure1.call(SelectOptionByLabelKeyword.groovy) at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:20) at com.kms.katalon.core.webui.keyword.builtin.SelectOptionByLabelKeyword.selectOptionByLabel(SelectOptionByLabelKeyword.groovy:98) at com.kms.katalon.core.webui.keyword.builtin.SelectOptionByLabelKeyword.execute(SelectOptionByLabelKeyword.groovy:71) at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:72) at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.selectOptionByLabel(WebUiBuiltInKeywords.groovy:1200) at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$selectOptionByLabel$4.call(Unknown Source) at Script1558520874956.run(Script1558520874956.groovy:29) ... 11 more )

Aucun commentaire:

Enregistrer un commentaire