top of page

Forum Posts

info
Jul 12, 2021
In BotPlay Community Support
If users are getting below error while running automation scripts using BotPlay automation bot, this is due to using user defined (UD:) element which is not added in the run time environment. Please add the user defined element and then use it in the script. java.lang.AssertionError: User defined [Grammarly.FileUpload_b] element returned from webservice has an error or is not added. Value - [null]. Please check if you have added data to the BotPlay's runtime environment. at org.junit.Assert.fail(Assert.java:88) at org.junit.Assert.assertTrue(Assert.java:41) at com.stellar.stellarui.useraction.util.DataFromWebService.getValueFromPropFileOnWebService(DataFromWebService.java:81) at com.stellar.stellarui.useraction.util.DataFromWebService.getXpathByORName(DataFromWebService.java:61) at com.stellar.stellarui.useraction.stepdefination.WindowsStepDef.upload_file(WindowsStepDef.java:24) at ✽.upload file "***file path**** to "UD:Grammarly.FileUpload_b" element(file:///***file path***automation_scripts/Sample%20Scripts/FileUpload.feature:6) Screen shot of the BotPlay's execution report with error when user defined element is not added to the BotPlay's runtime environment. Refer this link to learn how to use user defined elements - https://www.botplayautomation.com/post/six-codeless-ways-to-automate-test-elements-using-botplay-codeless-automation
Error due to using user defined (UD:) element without adding it to BotPlay's runtime environment content media
0
0
14
info
Jul 12, 2021
In BotPlay Community Support
Users getting below error on running BotPlay is due to badly formatted automation script .feature file. Please correct the format as per cucumber standard feature file format and bot will work as expected. C:\Users\*******\Documents\BotPlay\bot>java -cp .;.\bin\*;.\src\test\resources\* org.junit.runner.JUnitCore TestRunner JUnit version 4.13.2 .E Time: 0.018 There was 1 failure: 1) initializationError(TestRunner) io.cucumber.core.gherkin.FeatureParserException: Failed to parse resource at: file:///C:/Users/codemantra/Documents/BotPlay/bot/./automation_scripts/Login/SampleFileUpload.feature (2:1): expected: #TagLine, #FeatureLine, #Comment, #Empty, got 'Scenario: File upload to Grammarly site.' (3:1): expected: #TagLine, #FeatureLine, #Comment, #Empty, got '* launch "https://www.grammarly.com/plagiarism-checker"' (4:1): expected: #TagLine, #FeatureLine, #Comment, #Empty, got '* upload file "Z:\apache-maven-3.8.1\README.txt" to "UD:Grammarly.FileUpload" element' (5:1): expected: #TagLine, #FeatureLine, #Comment, #Empty, got '* close browser' (6:0): unexpected end of file, expected: #TagLine, #FeatureLine, #Comment, #Empty at io.cucumber.core.gherkin.messages.GherkinMessagesFeatureParser.parse(GherkinMessagesFeatureParser.java:52) at io.cucumber.core.feature.FeatureParser.parseResource(FeatureParser.java:47) at java.base/java.util.function.BiFunction.lambda$andThen$0(BiFunction.java:70) at io.cucumber.core.resource.ResourceScanner.lambda$processResource$1(ResourceScanner.java:79) at io.cucumber.core.resource.PathScanner$ResourceFileVisitor.visitFile(PathScanner.java:75) at io.cucumber.core.resource.PathScanner$ResourceFileVisitor.visitFile(PathScanner.java:60) at java.base/java.nio.file.Files.walkFileTree(Files.java:2804) at io.cucumber.core.resource.PathScanner.findResourcesForPath(PathScanner.java:53) at io.cucumber.core.resource.PathScanner.findResourcesForUri(PathScanner.java:31) at io.cucumber.core.resource.ResourceScanner.findResourcesForUri(ResourceScanner.java:61) at io.cucumber.core.resource.ResourceScanner.scanForResourcesUri(ResourceScanner.java:134) at io.cucumber.core.runtime.FeaturePathFeatureSupplier.loadFeatures(FeaturePathFeatureSupplier.java:62) at io.cucumber.core.runtime.FeaturePathFeatureSupplier.get(FeaturePathFeatureSupplier.java:45) at io.cucumber.junit.Cucumber.<init>(Cucumber.java:158) FAILURES!!! Tests run: 1, Failures: 1 C:\Users\*******\Documents\BotPlay\bot>echo "------Automation Stop-------" "------Automation Stop-------" C:\Users\*******\Documents\BotPlay\bot>pause Press any key to continue . . .
0
0
638

info

More actions
bottom of page