Looking for a tool to UI testing on Linux .Platform used for development is django.
The idea is that the analysts will capture the tests thru some UI and it will be able to be played back over and over again.
Try with Selenium IDE, http://seleniumhq.org/projects/ide/
Related
What Im trying to achieve is to write UI tests for my MVC4 web application using Watin. Now I create a Browser object and open on URL localhost:xxxxx.
Problem is that the code running on localhost:xxxx using IIS Express is using production code which I dont want to be doing during test. In test I want for instance my IAuth and IDataProvider implementations to behave differently.
How do you UI test on a mocked instance of your application?
Ideas? :)
Solution was to make a bat file which runs a msbuild command which deploy to my local IIS. This works like a charm.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe C:\Source\...\ProjectName.csproj /p:DeployOnBuild=true /p:PublishProfile="UnitTest" /p:Platform="Any CPU" /p:OutputPath="C:\inetpub\web" /p:VisualStudioVersion=11.0
I have a phantomjs script that navigates to some pages and store some information about them in a file. Now I want to unit test this script. My problem is that usually the frameworks test my code on client side, so I can't use the PhantomJS API.
I tried to use jasmine-node (https://github.com/mhevery/jasmine-node). It works "server-side", but I can't use all the PhantomJS API because it obviously run my tests with nodejs instead of phantom. Is there a better option to test PhantomJS apps at server-side?
I found two solutions. I think the most complete way to test phantomJS at "server side" is to use CasperJS.
Another solution I have found looking at the phantomjs source code. They use jasmine for testing and it's possible to apply the same idea to my own tests. The run-tests.js is the starting point for this approach.
Right now this is my workflow to write tests for a website:
Record using Selenium IDE plugin in Firefox
Export Test Case As >> PHP (PHP Unit)
Run the tests on a Windows machine that has PHPUnit installed as well as the Selenium extension for it using this command:
phpunit --verbose --log-junit some\path\result.xml some\path\test.php
What this command does is runs the test and saves the output (assertions and failures) in a log file called result.xml. And all has been good.
But now I have run into a need to test a part of the site that involves flash and I am using an application called Arthropod to capture the requests and responses coming to and from the flash component on the site.
Is there any way I can get selenium to to capture the text that appears on this program's interface?
I believe Arthropod is an AIR application. If it is associated with the browser you may try using seleniumForAir for your testing.
You may like to have a look here.
I'm looking for best practices to test Sencha Touch 2 apps. ideally, i would like to automate the execution of test sets (Via CI for example).
I've Looked for test frameworks like Jasmine, JSTestdriver. There is not a lot of feedback about using those frameworks with ST2.
Any ideas ?
To test my Sencha Touch application, I use Ruby with the gems Cucumber and Capybara.
It basically allows you click through the application.
Here's basically how to set up your environment. It says 'on windows' but it works as well on mac.
http://www.richardlawrence.info/2011/08/20/getting-started-with-ruby-cucumber-and-capybara-on-windows/
You can download a starter project at the end of the article.
I've got jsTestDriver up and running, and I use jstd-maven-plugin to run the tests during a build.
The plugin needs a browser to be specified in order to work though, and I'd like to use something like rhino or htmlunit that won't actually launch a browser.
The jasmine-maven-plugin does this with htmlunit, and works quite well.
Is there a way to specify a headless browser for jstd-maven-plugin?
One of the reasons that I prefer JsTestDriver over other JavaScript testing frameworks, is that the tests are made on real browsers, and allows me to test on all the major browsers that consumes my application, and verify compatibility issues with older versions of IE for example.
If you prefer to run a complete headless JavaScript testing server, perhaps JsTestDriver is not your best choice. I think CasperJS is a very good alternative to achieve that. It uses PhantomJS, a scriptable headless WebKit engine to run the tests.
In my case, I have a complete headless server running an instance of JsTestDriver, and Other server whit a couple of virtual machines, with common SO/Browsers combinations (Windows/IE7; Windows/IE8; Linux/Firefox...), which have actual browsers connected to the headless JsTestDriver server. But if you don't need to use real browsers, the CasperJS alternative may be a good choice.
JsTestDriver need a browser to run the javascriptcode. So there is no way to run your tests without a browser.
There is a way to open the browser in a virtual monitor. This is described in this question:
Run Headless JsTestDriver?
JSTD maven plugin can be extended to run phanatomjs.