Libraries & Frameworks

I am trying to automate UI for a site designed in Angular and when I inspect the browser (Chrome) with UISpy.exe, I find that certain controls do not exist in the tree at all, even though I can see them in the browser.

In certain cases, multiple fields (e.g. Transaction Date, Delivery Date, their labels, text and icons) exist as one control on the UI tree.

Here is an example of controls that seem to exist as a single control in the UI tree

I used Developer tools to extract HTML for this and here it is.

<div class=”input-daterange form-group right-inner-addon” ng-class=”{‘has-error’: submitted &amp;&amp; requisitionForm.transactionDate.$invalid}”>
<label for=”transactionDate” class=”ng-binding”>Transaction Date<span class=”asterisk_input”> </span></label>
<input date-picker=”” type=”text” id=”transactionDate” today=”” class=”form-control date-picker input-lg ng-isolate-scope hasMultiCalendarPicker ng-valid ng-valid-required ng-valid-valid-date-format ng-dirty” name=”transactionDate” ng-model=”requisition.transactionDate” aria-label=”Transaction Date” aria-required=”true” required=”” autocomplete=”off” placeholder=”MM/DD/YYYY” title=”Press F9 to open the calendar”><span class=”calendar-icon calendar-img”></span>
</div>

However the UI tree in UISpy shows just a single control on the UI tree.

How can I automate and access individual items on the screen, e.g. Transaction Date Label, the value for Transaction date only etc..?

Website: https://myir.ird.govt.nz/eservices/home/?link=RWTEXREG
I’m attempting to download this file. It looks like the request is handled server side so there isn’t any download link per se.
I’ve tried a bunch of things, including:
result = driver.find_element_by_xpath(“//span[contains(@class,’CaptionLinkText’)]”).text

But I really feel like I’m out of my element (no pun intended) with this.

I have a JMeter script in which I’m extracting value from the response of first request via Regular Expression Extractor and sending it in the second request.

This mechanism works fine 80 percent of times but fails for the remaining 20 percent! When it fails the value passed in the second request displays as “NOT FOUND” in the ‘View Results Tree’ Request Body section. Although, the preceding first request gave the response in the exact expected manner.

I am currently working on integrating Cypress e2e tests in our existing CI/CD pipeline (I’m not an automation engineer but a developer). Our application is a fintech app which involves the typical process of registering a new business, and after the business has been registered, to go through the process of requesting a credit with it.
So far we only have a few e2e tests for registering the business, which are fine. And then we are creating a few e2e tests for the business credit request flow. But then, we want to create other tests that comprises the whole flow of creating a business + requesting a credit. However I’m just wondering what is the best way to reuse the code from the tests where the business is created instead of repeating the code in the new tests.
Just wondering what is the most elegant way to do it, either if Cypress itself offers some sort of functionality to reuse that, or just encapsulate the test code in utility functions that can be called from several tests.

I have imported all web3J library and using tried using java_version 16,17 and 20. Every time I am facing issue. When I compiled that script in VSCode. I am facing the same issue. Can someone please help me with groovy script?
import org.web3j.protocol.Web3j
import org.web3j.protocol.core.DefaultBlockParameterName
import org.web3j.protocol.http.HttpService
import org.web3j.tx.RawTransactionManager
import org.web3j.tx.Transfer
import org.web3j.utils.Convert
import org.web3j.protocol.core.methods.response.TransactionReceipt
import org.web3j.crypto.Credentials

def web3 = Web3j.build(new HttpService(“API_URL”))
String PRIVATE_KEY = ‘b33ccb143751577968f32575ee690eb3873e49f27935708dbdea52fe36b6ba76’
RawTransactionManager rawTransactionManager = new RawTransactionManager(web3, Credentials.create(PRIVATE_KEY))
Transfer transfer = new Transfer(web3, rawTransactionManager)
println “transfer: ${transfer}”

TransactionReceipt receipt = transfer.sendFunds(“0x7de3280c66ecee8f4cbd8fb78850229d8f10d22f”, (Convert.toWei(“1”, Convert.Unit.ETHER).toBigInteger()), Convert.Unit.WEI, 30000, 1000000108).send()

println(“Transaction Hash: ${receipt.transactionHash}”)
println(“Block Hash: ${receipt.blockHash}”)
println(“Block Number: ${receipt.blockNumber}”)
println(“Gas Used: ${receipt.gasUsed}”)
println(“Contract Address: ${receipt.contractAddress}”)

I am looking into some use cases of AI based tools that can be used to test functionality of a product more effectively.
Are there any AI testing tools that work like Generative AI where test scenarios is written in text prompt and testing is performed by the AI tools?
Kindly list some free AI tools that one can learn and explore?

The tech space and digital business era witnessed a sudden and concerning rise in cyber-attacks in the 2024 Q3. On average, 1,876 cyber-attacks per enterprise were recorded, 75% more than the 2023 Q3 data. If we talk about which industry was primarily affected, the education/research sector would top the list with 3,828 attacks per week, … Cyber Extortion: Protecting Your Business from Digital Blackmail 
The post Cyber Extortion: Protecting Your Business from Digital Blackmail  first appeared on TestingXperts.

]I’m automating baseball sports reporter application. My application is a desktop application. I’m using winium tool with java language. In my application table contain player names in alphabetical order. I want to select 8 players from the list in same order as you can see above order. And also I want to select the matching positions.

These are the players that i need to select::

#players names :: positions
Happ = CF
Bryant = 3B
Rizzo = 1B
Contreras = C
Schwarber = LF
Russell = SS
Heyward = RF
Baez = 2B

now i need to select the particular players that I mentioned above list order.
My application manual working process is first double click a player and mean time a window came to select the position by single click. example firstly , I need to select the player Happ and his position CF(center field) then select the player Bryant and his position 3B(third base) etc…

public void awayTeamHitters() {

try
{
String[] players = new String[]
{
“Happ, Ian#”,
“Bryant, Kris”,
“Rizzo, Anthony*”,
“Contreras, Willson”,
“Schwarber, Kyle*”,
“Russell, Addison”,
“Heyward, Jason*”,
“Baez, Javier”
};
String[] positions=new String[]
{
“CF”,
“3B”,
“1B”,
“C”,
“LF”,
“SS”,
“RF”,
“2B”
};

List<String> playersInList = Arrays.asList(players);
List<String> positionsInlist=Arrays.asList(positions);
//selecting players of 2 table
driver.findElement(By.id(“lblAwayTeamHittersAll”)).click(); // click on 2 tables all players
WebElement table1 = driver.findElement(By.id(“lsvAwayTeamHitters1”));
WebElement table2 = driver.findElement(By.id(“lsvAwayTeamHitters2”));
//taking row size
List<WebElement> rows1 = table1.findElements(By.xpath(“./*[contains(@LocalizedControlType, ‘item’)]”));
List<WebElement> rows2 = table2.findElements(By.xpath(“./*[contains(@LocalizedControlType, ‘item’)]”));
//create string array add players to player_table1
List<String> player_table1=new ArrayList<String>();
for(int i=0;i<rows1.size();i++) {
List<WebElement> cols1 = rows1.get(i).findElements(By.xpath(“./*[contains(@LocalizedControlType, ‘text’)]”));
for(int j=3;j<cols1.size();j++) {
String celtext1 = cols1.get(j).getAttribute(“Name”);
player_table1.add(celtext1);
}
}
//create string array and add players to player_table2
List<String> player_table2=new ArrayList<String>();
for(int i=0;i<rows2.size();i++) {
List<WebElement> cols2 = rows2.get(i).findElements(By.xpath(“./*[contains(@LocalizedControlType, ‘text’)]”));
for(int j=3;j<cols2.size();j++) {
String celtext2 = cols2.get(j).getAttribute(“Name”);
player_table2.add(celtext2);
}
}

//combine player table 1 and 2
player_table2.addAll(player_table1);
List<String> player_table3=new ArrayList<String>();
player_table3.addAll(player_table2);
System.out.println(player_table3); //it will print the 25 player names
int p=player_table3.size();
System.out.println(p); //it will print the size 25
for(int i=0;i<p;i++) {
if(playersInList.contains(player_table3)) {

Actions act = new Actions(driver);

act.doubleClick(playersInList).build().perform();
}

WebElement pos= driver.findElementById(“PlayerPositions”);
List<WebElement> col=pos.findElements(By.xpath(“./*[contains(@LocalizedControlType, ‘button’)]”));

if(positionsInlist.contains(col)) {

pos.click();

}
}

}
catch (Exception e) {
System.out.println(e);
}
}
}

I have 2 tables in my application and I add it into one list..
Here double click action is not performing and after printing 25 player names and size .it will got stop.

I’m trying to make Katalon chrome extension to click the dd/mm/yyyy language.
But the problem is when I record the click on dd/mm/yyyy Katalon records
xpath=(.//*[normalize-space(text()) and normalize-space(.)=’Select Language’])[2]/following::li[1]

Now for this, when the test case is run, it selects the Select Language value
BUT, if I select mm/dd/yyyy from the drop-down Katalon records
xpath=(.//*[normalize-space(text()) and normalize-space(.)=’English (UK) – dd/mm/yyyy’])[2]/following::li[1]

And now when I run the test case, it will select mm/dd/yyyy and not dd/mm/yyyy
It seems the selection is offset by 1.

In the below pic, I need to click on the icon in a row which is newly added and column1 value is stored as global variables.

Have used the below code, unable to find a solution.
WebElement userListTable = driver.findElement(
By.xpath(“//*[@id=’KendoActiveCorpUserGrid’]/div[2]/table”));

List<WebElement> rows_table = userListTable.findElements(By.xpath(“//*[@id=’KendoActiveCorpUserGrid’]/div[2]/table/tbody/tr”));

int rows_count = rows_table.size();

for (int row = 0; row < rows_count; row++){
if(ResultName.getText().equalsIgnoreCase(globalVariables.NewCorpUserName)){

}
}

Need to click on element id avaialble in that row:

//*[@id=”CGOLK90700779C”]/span/span/i[3]

ResultName is the position for which variable is stored globally.

When covering cross-browser testing using Selenium WebDriver, how do you provide the browser and version information to the tool (e.g. BrowserStack, Sauce Labs)? For example, you’re wanting to execute your tests against multiple versions of Chrome, Edge etc.

I have been experimenting with reading a CSV file of browser data and using that to set Selenium capabilities before iterating through that CSV file in the code. Now, I am wondering if there’s a better way, generally, as I suspect this method will affect parallel execution.

I am trying to run a sample test to collect server metrics through Jmeter plugin perfmon.

I have an application running in localhost and I have perfmon metrics collector and server agent installed and have checked if they are working fine. There are no issues.

My http sampler works fine and generates results too but I do not see anything in the graphs.

My test ramps up 1000 users in 100 seconds, still nothing in graphs. What am I missing?

I have around 10 Selenium/Java projects in Eclipse IDE and there is “utils” package and Automation framework classes that i manually copied to all projects and all those have different versions or code in it.
So, like ‘ExcelReader.java” utility class in my Automation framework has 10 different copies, each one in separate Project folder/structure. Now, all my code is hosted in Azure DevOps Git repos and i use eGit eclipse plugin to commit/push changes.
How can i keep just one copy of “Utils” package in Git repos and all individual projects just use that one central copy directly into it and if one tester updates central copy then all projects can “fetch’ lastest code automatically.
AutomationProject1 -> Utils package/customized classes [All projects have different copies of same class]
AutomationProject2 -> Utils package/customized classes
AutomationProject3 -> Utils package/customized classes
AutomationProject4 -> Utils package/customized classes
AutomationProject5 -> Utils package/customized classes

A simple, lightweight, and privacy-focused product analytics php package. Source: Read MoreÂ