Im new to using Selenium Grid so I don't really know that much about it. What im trying to do is simulate 400 users using my website. I can create the test script that simulates the users actions but im not sure how to use Selenium grid to simulate 400 users using the website at once. Any help or useful tutorials would be appreciated.
At the moment im using selenium webdriver and firefox driver to simulate one users actions. All my tests are being run through eclipse.
I think what you are looking is a Grid implementation but not using a standard webbrowser. I think what you want is to just do a multi-threaded GhostDriver test by registering GhostDrivers to your Grid nodes. You can use TestNG to fork the threads using a TestNG instance generating class factory.
Related
I have a web application running on tomcat.My application has no GUI.It processes files on some locations and persists values into the database and produce some output files on some locations.
I need to Automate testing of this application using selenium.This includes file creations, file movements between folders..etc.
My question is
1.Is it possible to automate this non-GUI application using selenium?How?
2.Is it possible to include these file creations, movements and DB values checking using selenium web driver
If you look at the Home Page of Selenium it is clearly mentioned that :
Selenium is the most widely-used open source solution in building Test Automation for Web Applications. The suite of tools provided by Selenium results in a rich set of testing functions specifically catering to the needs of testing of web applications of all types. These operations are flexible and allows many options for locating UI elements and comparing expected test results against actual application behavior.
As your Automation Testing requirement is :
File Creation
File Movements between folders
It seems Selenium may not be the appropiate tool.
A framework built through Perl or Python may better cater to your requirement.
Selenium is created to automate test on UI. You can use on Page Object Model or directly on findelement(or findelements) but you have to give a locator attribute which it can be according to selenium documentation:
id
name
xpath
link_text
partial_link_text
tag_name
class_name
css_selector
So if you have these locators yes, but if you don't, Selenium is not suiting for this task. Maybe you looking for an API tester, Unit tester or what are you trying to accomplish?
Dear Selenium IDE Friends.
I test my webapplication via Firefox-Plugin Selenium IDE. I have to test: sending a newsletter and verify the newsletter-text. Selenium IDE cant´t break out of the browser to move to my outlook, so i have to use a webmailer. Some webmailer like 1und1 or freenet have frames in the layout. Selenium IDE doesn´t select elements in frames, even not by function "selectFrame".
MY Question: Which Webmailer has no frames and supports testing with Selenium IDE?
Best option: Let your developers build you some in-house web mail suitable for such testing.
If thats not an option, try 10minutemail
You get new inbox every time (new e-mail address)
No frames
Selenium IDE should be able to read it
Of course. As long as you are about to use 3rd party app for your testing, consider donating some money to them ;)
My team is about to start using Vaadin and wants to integrate Selenium tests to allow for Test-driven development.
However I've heard there are issues with recording Selenium scripts out of the box with Vaadin and I'm wondering what practices we need to follow to make sure the scripts can be recorded easily?
If you use Vaadin use setDebugId(String id) method. All visual components has this method. After that you simply select element by ID.
WebDriver it look like:
WebElement el = webDriver.findElement(By.id("yourElementId"));
el.sendKeys("123");
Selenium 1.0
selenium.type("id=yourElementId", "123");
But sometime you will need more complex selector. In our project we use XPath with element id.
WebDriver it look like:
WebElement el = webDriver.findElement(By.xpath("//div[#id='yourElementId']/div"));
el.sendKeys("123");
Selenium 1.0
selenium.type("//div[#id='yourElementId']/div", "123");
The best way would be to get pro user accounts for your team and use the vaadin testbench. You can then profit from the experiences made by senior vaadin developers and save a lot of effort.
I need to test user chat system with selenium. Currently I do that manually by opening two browsers, logging in each with different test user, and send messages between the two users.
My question is how I can automate that with selenium?
Actually I never tried that, but I guess you can easily have two different instances of WebDriver:
driver1 = new FirefoxDriver();
driver2 = new FirefoxDriver();
should IMHO run two different Firefox browsers where you can play around. But again, I never tried this approach, so I might be wrong
Its hacky, but could you run two instances of Selenium then run two tests simultaneously?
Two drivers seems like a nice fit. If that's not possible, try using two different frameworks.
HeadlessUnit and Selenium, for example. Don't really know if they would be stepping on each other toes.
I have started using Selenium WebDrivers to automate some performance testing. I found out that we could take screenshots of a page after the page has completed loading using WebDrivers: http://seleniumhq.org/docs/04_webdriver_advanced.html#taking-a-screenshot. However, I want to be able to take screenshots while the page is loading to analyze its loading time and pattern, much like what webpagetest does (http://www.webpagetest.org/). Is there an API that I could use to accomplish this task using WebDrivers?
I am using the FirefoxWebDriver and the Java client for the same. I appreciate help or tips.
Thanks!
Since, I found out that the RemoteWebDriver's get calls are blocking and even the getScreenshot calls are blocking, I decided to run java.awt.Robot in a separate thread and capture screenshots while the WebDriver loads the page.
The only caveat is that the browser instance opened up by the WebDriver has to be in the front of the screen to take snapshots correctly. I am exploring if Robot can take snapshots on an Xvfb display, which would be just awesome and would work for my purposes.