How to find the UpgradeCode and ProductCode of an installed application in Windows 7

IMPORTANT: It’s been a while since this answer was originally posted, and smart people came up with wiser answers. Check How can I find the Upgrade Code for an installed MSI file? from @ Stein Åsmul if you need a solid and comprehensive approach. Here’s another way (you don’t need any tools): open system registry … Read more

Karate- Need help to assert a single dimension array for date range

Here you go: * def dateToLong = “”” function(s) { var SimpleDateFormat = Java.type(‘java.text.SimpleDateFormat’); var sdf = new SimpleDateFormat(“yyyy-MM-dd’T’HH:mm:ss.SSS”); return sdf.parse(s).time; } “”” * def min = dateToLong(‘2019-04-24T17:25:00.000’) * def max = dateToLong(‘2019-04-24T17:50:00.000’) * def isValid = function(x){ var temp = dateToLong(x); return temp >= min && temp <= max } * def response = … Read more

Karate UI drag and drop [duplicate]

Drag and drop is actually quite hard to get right, so I recommend doing this via JavaScript. Executing JS is actually quite easy using Karate: * driver ‘https://www.seleniumeasy.com/test/drag-and-drop-demo.html’ * script(“var myDragEvent = new Event(‘dragstart’); myDragEvent.dataTransfer = new DataTransfer()”) * waitFor(‘{}Draggable 1’).script(“_.dispatchEvent(myDragEvent)”) * script(“var myDropEvent = new Event(‘drop’); myDropEvent.dataTransfer = myDragEvent.dataTransfer”) * script(‘#mydropzone’, “_.dispatchEvent(myDropEvent)”) * screenshot() … Read more

headless internet browser? [closed]

Here are a list of headless browsers that I know about: HtmlUnit – Java. Custom browser engine. Limited JavaScript support/DOM emulated. Open source. Ghost – Python only. WebKit-based. Full JavaScript support. Open source. Twill – Python/command line. Custom browser engine. No JavaScript. Open source. PhantomJS – Command line/all platforms. WebKit-based. Full JavaScript support. Open source. … Read more