katalon-studio

Converting JavaScript to Groovy/Java

亡梦爱人 提交于 2019-12-24 04:09:29
问题 I have some javascript code (Postman) that needs to be converted for use in another API test tool (Katalon). I am getting errors while updating the date with the timezone difference. The error occurs when trying to update the expectedDate with the TZ difference. Original Javascript //Postman - Validate Date /*var jsonData = pm.response.json(); var expectedDate = new Date(); var firstDate = new Date(jsonData[0].Date); var locationOffset = Number(pm.environment.get("locationOffset")); var

katalon studio can't load my variables at variable binding section

こ雲淡風輕ζ 提交于 2019-12-20 03:41:51
问题 I wrote a test case and save all text field as variables then I filled in the values in excel, but after I add my Test case and test data to test suite,the variable section can't load my variables. How does this comes out ? 1.Test suite screenshot 2.Variables in test case 回答1: This can be the case that your variables are not setup properly in Variables section of your Test Case. 回答2: After you created your data file you have to use getter to use up values in a test case. A short example:

How can I use JavaScript in Katalon Studio?

一个人想着一个人 提交于 2019-12-13 09:19:51
问题 Sometimes, I encounter an element which I'm unable to click with a normal Selenium script so I have to use javascript to execute my script. How can I use JavaScript in Katalon Studio? 回答1: I believe you mean, Executng the Javascript code and get the element. You can try this appraoch - https://docs.katalon.com/display/KD/%5BWebUI%5D+Execute+JavaScript 回答2: ((JavascriptExecutor) DriverFactory.webDriver).executeScript('Your JavaScript-Code', argument); 回答3: You can try using a custom keyword,

Katalon Studio creating element with webDriver not recognised when used in Javascript

送分小仙女□ 提交于 2019-12-13 04:16:01
问题 I'm trying to use the executeJavascript method in Katalon Studio, and having written a couple lines of code that look really similar to that in the documentation example: documentation example: my script: I have also imported WebElement in my script: However, when I run my test I get this error message: Test Cases/Forms/Test1 - fill in maintenance request form FAILED because (of) Unable to execute JavaScript. (Root cause: org.openqa.selenium.WebDriverException: unknown error: element is not

Unexpected job aborting in jenkins when using katalon to execute automatic tests

走远了吗. 提交于 2019-12-11 08:40:09
问题 I’m executing automatic tests using Katalon in console mode. Sometimes job executed by Jenkins ends unexpectedly without any error. Katalon Studio version 5.10.1, Jenkins version 2.121.3 I've tried to find some Jenkins logs other than console logs, which logged why that job is aborted Jenkins console logs: /var/lib/jenkins/.katalon/5.10.1/Katalon_Studio_Linux_64-5.10.1/katalon -noSplash -runMode=console -projectPath=/var/lib/jenkins/workspace/(...) -browserType=Firefox -testSuitePath=Test

How to configure the Test suite Collection Report in Katalon Studio?

我们两清 提交于 2019-12-11 07:21:59
问题 While configuring the Test suite collection, we will add the profile information for each test suite. Is it possible to add 'Profile' column to the Test suite Collection Report and also to the Exported HTML of Test suite Collection? My TestSuiteCollection looks like: Test Suite Collection My TestSuite Collection Report looks like: Test Suite Collection Report Is there any way to add this 'Profile' column to Report? 来源: https://stackoverflow.com/questions/53314797/how-to-configure-the-test

Recommendation about the code construction

只愿长相守 提交于 2019-12-11 06:08:05
问题 I have tried to automate the login with Katalon Studio and Selenium|testNG. I have used XML file to send the browser value to the script, which I have pasted here. public class TC_Testportal { private WebDriver driver; private String baseUrl; @Parameters("browser") @BeforeMethod public void beforeMethod(String browser) { if (browser.equals("firefox")) { System.setProperty("webdriver.gecko.driver", "drivers\\geckodriver.exe"); driver = new FirefoxDriver(); baseUrl = "https://test.com"; driver

In Katalon Studio how to tap an iOS app’s element when it doesn’t have either label or name object properties

折月煮酒 提交于 2019-12-11 06:06:45
问题 KS 6.3.2 is able to tap on an element that contains label or name object properties. However, the application that I have under test has an element which is a button and does not contain either label or name or any text. Furthermore, the xpath of that element is dynamic. The following are the snapshots of the Object’s properties of the same element of an application captured from 2 different devices: The following is the Selected Locator’s value: My Page 1: //XCUIElementTypeApplication

Katalon: When is a GlobalVariable reset?

烈酒焚心 提交于 2019-12-10 23:19:42
问题 When using Katalon and changing the values of a GlobalVariable during, before or after a test case or test suite, when exactly does the changes reset to the defined value in the profile? 回答1: The value of the GlobalVariables is reset to default on the teardown of the test suite (or the teardown of a test case when a single test case is run). For example, if you have GlobalVariable.x=1 set in the Global Variables and you have GlobalVariable.x=2 line in your test case, after the test case ends,

Katalon studio Java jar files

本秂侑毒 提交于 2019-12-10 15:54:01
问题 I want to use my Java code in Katalon studio, but I don't know which .jar files I have to import to Katalon. I read all the documents which were provided by Katalon and read all forum posts regarding java code use in Katalon. I did not find the proper answer and steps which Java .jar files I have to use and how to download Java .jar files? Screenshot Kindly suggest, please. 回答1: after you add the external libraries, you need to import them on the test cases. Katalon has two ways of using