automation

In Sikuli, How to find and click a minimum of 3 identical images?

眉间皱痕 提交于 2019-12-23 02:09:07
问题 I'm trying to click no less than 3 of the same image, but with findAll() I am having difficulty with sikuli wanting to select only 1 image when I don't want it to select any if there is not 3 or more. if exists(Pattern("1474201252795.png").similar(0.95)): wait(1) for x in findAll(Pattern("1474201252795.png").similar(0.95)): click(x) 回答1: So just count the images first and check if the count is higher than 3. imageCount=0 images = [] # find all images and store them in a list to prevent

automating install.sh script using an expect script

时间秒杀一切 提交于 2019-12-23 02:06:07
问题 I have a bit of a quandary that I can't seem to figure out, and i'm sure it's easy.. I have an external shell script, we will call it "install.sh" that is used to install a piece of software that our company develops. I want to automate that install.sh process using expect (with external arguments), since it's pretty easy to pattern match on the output strings and pass in a bunch of arguments, either as an array or arguments to the expect script. Unfortunately, many of the examples online are

store files to filepicker.io from the command line?

白昼怎懂夜的黑 提交于 2019-12-23 01:58:20
问题 I have a bunch of files, I'd like to push them all to filepicker and use various convert options to manipulate them. How do I automate this process? Is there a way to do this outside of javascript with a traditional scripting language I can run from the command line? 回答1: The way to do this is as a POST to /api/store/S3 with the contents of the file. For instance curl -F fileUpload=@test.html 'https://www.filepicker.io/api/store/S3?key={{apikey}}&filename=myCoolFile.html' There are other

How do I programmatically check for open browser instances on a Windows machine?

好久不见. 提交于 2019-12-23 01:28:07
问题 I wrote a GUI automation script in python that opens a web browser, does some tests in the browser and then closes the browser. It does so in a loop going up through hundreds of thousands of iterations. I've run into problems where the program would hang and I would get no browser instances open or sometimes up to 20 instances open. I would like to create an error check to make sure there is only one browser instance open at a time (kill the browser completely and restart the iteration if

selenium Test case for facebook login and logout

岁酱吖の 提交于 2019-12-22 22:16:32
问题 Scenario is to Login to facebook account and then logout. I tried using xpath className and id. But everytime it shows error as ElementNotfound or element not visible. Later I Checked it using SELENIUM IDE and got this xpath for the LOGOUT link. But still the error persists. Kindly help me. public class FacebookLogin { public static void main(String[] args) throws InterruptedException { // TODO Auto-generated method stub WebDriver driver = new FirefoxDriver(); driver.manage().window()

Screen resolution changes for the remote machine after safely closing the RDP session with “SupressWhenMinimzed”

岁酱吖の 提交于 2019-12-22 18:32:39
问题 First of all sorry for the (maybe not so specific) title as it consists of multiple topics. The issue atm i'm having is related to my test automation setup. It consists of a linux machine handling the BE + FE and starting of the test themselves. And a Windows Server 2008 (Terminal) to which i connect through RDP session and it's the place the actual tests are run. For automation purposes i use Ranorex. First of all how i have the Win machine set up: As Ranorex is a GUI test automation tool it

Is it possible to automate two apps at the same time in iOS?

半城伤御伤魂 提交于 2019-12-22 18:17:24
问题 We have this scenario: Execute the script in app1, in certain step app1 sends us a SMS with a URL, app1 is expecting a validation code in a textfield We have to open SMS app to verify if SMS exists, this SMS has a URL and when we click on it, it sends us to app1 again but automatically the validation code is written in the textfield. then, continue with the script. is it possible to do this? what do we need to make it? Thanks. 回答1: Yes, As per your scenario you have to launch the messages

python pyautocad,how to contruct an objectlist for COM

只愿长相守 提交于 2019-12-22 18:05:12
问题 This is an real project write by VBA before. I want change it to python for data processing is heavely. And, use 'ActiveX Automation scripts for AutoCAD with Python' method. code is below.My question is, how to contruct an object list for AddRegion? Maybe comtypes have some topic about VARINT. I really have no experience about COM and so on... # -*- coding: utf-8 -*- from pyautocad import Autocad, APoint, aDouble acad = Autocad(False, True) acad.prompt("Hello, Autocad from Python\n") print

Error : Target failed to run: Permission to debug com.apple.Preferences was denied

拈花ヽ惹草 提交于 2019-12-22 17:05:46
问题 Run first test on Appium and I got a error in the logs. Appium version 1.4.13 xcode version 7.2 iOS settings with appium: http://screenpresso.com/=nD2Cf. Here is my java code: import io.appium.java_client.AppiumDriver; import io.appium.java_client.MobileElement; import io.appium.java_client.ios.IOSDriver; import io.appium.java_client.remote.MobileCapabilityType; import org.openqa.selenium.WebDriver; import org.openqa.selenium.remote.DesiredCapabilities; import org.openqa.selenium.remote

Is there a way to control a third-party EXE file from VB.NET?

℡╲_俬逩灬. 提交于 2019-12-22 15:35:11
问题 My goal is to control an application from VB.NET. There is no API, and I do not have the source, only the compiled EXE file. Is there a way to find the opened application, find a button within the application, click a button and know it was clicked? Is there a way to read the contents of a textbox within the application? 回答1: Yes, with Windows Vista (or Windows 7, or Windows Server 2003 and later) there are "UI Automation" APIs. There are managed options; System.Windows.Automation is one,