You can do distributed builds in Jenkins to improve overall performance of your builds and to balance your load on different machines. There is no limit on the quantity of slaves, however, the concept might differ from Teamcity's build agents. You might want to read up on the reference link...

Just add THREE DOTS (...) in first cell before ELSE IF keyword ${txt} Set Variable ${txt}= Run Keyword If ${lenght} > 5 Some Keyword ... ELSE IF ${lenght} < 5 Some Keyword ... ELSE Some Keyword Log ${txt} ...

Ok, I found a FREE solution for this. I can use www.sikuli.org with Jenkins to test Windows applications. Sikuli uses the concept of image recognition. The good things about this are that: FREE , I can develop/maintain the app with .Net community version I can write test with my prefer...

You can do this more or less as you described. You can add a target which will fail to compile, then add a test which invokes cmake --build to try to build the target. All that remains is to set the test property WILL_FAIL to true. So, say you have...

I think the better approach you can use is get the assertion status of the testSteps, and then check if the status is FAILED, UNKNOWN or VALID. You can use the follow groovy code to do so: import com.eviware.soapui.model.testsuite.Assertable.AssertionStatus def TestCase = testRunner.getTestCase() def StepList = TestCase.getTestStepList() StepList.each{ // check...

Consult the surefire plugin documentation. It provides a way to specify that certain tests are not thread safe by using @NotThreadSafe annotation. Another solution is to specify two separate surefire executions with explicit test inclusions and exclusions. One execution could run in parallel mode including the thread safe suites, the...

You cant start an automated test execution run from the web ui, yet. http://nakedalm.com/execute-tests-release-management-visual-studio-2013/ You can however use an automated release triggered from a build to do it. And you can start a build in the UI......

I would suggest following based on your given little description about your need : 1 - For functionality testing and to make all your scenarios automate use Selenium WebDriver 2 -Then if you want to priorities your testes , want to run tests through XML , want to run multiple...

My solution to this problem was to split the two describe blocks in to 2 separate spec files. I figured this made more sense anyway, as each test had different conditions it needed to meet, and it isn't much hassle to have extra spec files.

As far as I currently know of, there is no solution to provide just that what you describe that you want. Best option is to use NUnit project files, modify settings there and pass the solution file to the runner. On the other hand, you could try to use the...

The purpose isn't to replace integration tests that will test modules from a higher level. Unit tests are intended to test a discrete class in isolation, mostly to confirm that the design and coding of that class is complete.

Alright, I have no idea why White DragAndDrop functionality isn't working (or manually using leftDown, move, leftUp). But I did find a solution. Essentially I re-wrote the white drag and drop function with a delay between each step. So it looks like the following: guiObject.Click(); Mouse.LeftDown(); var stepCount = 10;...

Add an entry to the app config. App Config: <appSettings> <add key="IsUnitTest" value="True" /> </appSettings> Then get the key/value pair from the config file and set your service dependency based on the config value. Test [TestClass] public class MyTest { IServices _service = null; [TestInitialize] public void Setup() { var...

If you are using VS 2012 or later, you should be using vstest.console.exe to run your tests. Mstext.exe is left there for backward compatibility. Using vstest.console.exe oftentimes fixes issues that only exist when run with mstest.exe.

I managed to restrict Travis CI tests to files that are actually modified in the pull requests. In .travis.yml you have a possibility to run a script before running tests. I used it to create a list of modified files: before_script: - git diff --name-only master > modified_files Then, in...

Mocking replaces a method in your code with something from your test. Which is exactly what you are asking to do. Using the rspec mocking framework as an example, you could, in your test, write: allow(SecureRandom).to receive(:random_bytes).and_return("My Test String") Then use the same input string to your #confirm_email code. Presuming...

Given that short page snippet, it is hard to tell. But I would try the following: Use Wait Until Element Is Visible prior to clicking the element. Use Set Selenium Timeout to set the timeout for this appropriately. You should get at least a better error message. Use Firefox console...

Ok, so I figured out how to do it for profiler sampling (not instrumentation)... Launch Visual Studio (VS) and open the project that has the automated test that you would like to profile. Put a breakpoint on the first line of the test that will be profiled. Debug the test....

Using assertTrue The assertTrue method has a second parameter, where you can specify a message that the assertion should throw when the assertion was negative: $this->assertTrue($someVariable == "foo", '$someVariable should have been "foo"') Using specialized assertion functions PHPUnit offers a myriad of specialized assertions (for equality, identity, array elements and...

Try to log/trace the values of TestRunDirectory (https://msdn.microsoft.com/en-us/library/microsoft.visualstudio.testtools.unittesting.testcontext.testrundirectory.aspx) and/or other properties of the context to see if you can figure it out. This is still on the local machine and not in TFS or other build system, right? Not sure what else to suggest. Edit: are you using the normal...

Chromedriver always starts totally fresh, nothing is keeping. There is option to re-use the existent one (using desired capability androidUseRunningApp) but unfortunately Appium any way will kill it. Please see more details in this post...

I referred to below link: selenium webdriver select element Select(WebElement element) So if you do something like this: @FindBy(id="foo") private WebElement wannabeSelect; Select realSelect = new Select(wannabeSelect); realSelect.selectByValue("myValue"); It should work. BTW, I am using the same approach as you in the "workaround" because I dont wanna cast new WebElement...

I had a similar problem. I don't know if this could solve yours: I wanted to touch a button but got the same exception as you. It worked perfectly in the console. I then realized that my test was entering text into a text field and the button was obstructed...

An easier way to get your link: public HtmlHyperlink link() { HtmlControl paragraph = new HtmlControl(brwsWin); paragraph.SearchProperties["InnerText"] = "Customers"; HtmlHyperlink target = (HtmlHyperlink)paragraph.GetParent(); return target; } So that you can now simply Mouse.Click(link()); I always like to use the BrowserWindow object itself as the parent, but by definition it shouldn't...

Actually it's simple to run an IDE test against 1 specific page (base url actually): java -jar selenium-server.jar -htmlSuite "*firefox" "http://baseURL.com" "mytestsuite.html" "results.html" So what you need to do is use jenkins (or any bash/batch script) to run that command multiple times with the base url set as "http://baseURL.com/page1", "http://baseURL.com/page2",...

1. NameError: name 'i' is not defined When you use the extended variable syntax, everything inside the curly braces is evaluated by the python interpreter. However, the i in your code is a robot variable, not a python variable. Also, to access an individual element of an array you need...

So we should start browser 2 times and it'll login as Test1 - Abc123 and Test2 - Abc123. In short you will need to get the (Login) comma separated string from the properties file, split it and keep it in a list. Use it in a for loop. List<String>...

Brad Wilson from xunit.net told me in this Github Issue that one should use LINQ's OrderBy operator and afterwards Assert.Equal to verify that two collections contain equal items without regarding their order. Of course, you would have to have a property on the corresponding item class that you can use...

OK, this is what I did. This approach doesn't require any change to the source code of the project. Installed imagemagick (..ck) i.e. yum install imagemagick on RHEL. Created a script on the target server and it works now. All I do is, in the Jenkins job, when I have...

You an perform UI tests through XCTest but it's designed for unit testing. Instruments has UI Automation which is designed for UI testing. Opening up XCTestAssertions.h will give you a pretty good reference for what's included in XCTest. Generally all the assertions follow a similar pattern: XCTAssertSomething(somethingBeingTested, @"A message to...

As we discovered in comments, updating Firefox to the latest version did the trick. The code looks really good to me and makes total sense. What I would try is to move to the element before making a click: Actions builder = new Actions(WebDriver); IWebElement saveButton = wait.Until(ExpectedConditions.ElementIsVisible(By.CssSelector(".button-wishlist"))); Actions hoverClick...

I could solve the problem myself. It was really the @UiThreadTest annotation. Just run the critical parts in the method shift.runOnUiThread(). public void testDeleteButton() { final Shift shift = getActivity(); final Button deleteButton = (Button) shift.findViewById(R.id.shift_delete); final int deleteButtonViewMode = deleteButton.getVisibility(); assertEquals(View.VISIBLE, deleteButtonViewMode); shift.runOnUiThread(new Runnable() { @Override public void run()...

According to the scoping rules multiple Scope bindings will be OR'd so I would expect the second example to work. Are you sure that you are spelling the feature name correctly? I'll try and get an example worked up to verify this behaviour....

you need to pass company_calender_id in params in specs, because you are passing it through hidden field and using it to find record in first line of update_by_day action. Try below one: put :update_by_day, {:day => company_calendar.day, company_id: @company.to_param, :company_calendar => { time_from: "2014-09-25 08:00:00", time_to: "2014-09-25 12:00:00" },:company_calendars_ids =>...

There is no isPresent function The isDisplayed returns True only if the element is displayed on the webpage and is actually visible. If you just want to check if the element is present then you can do one of the following: Put the code for findElement inside a try/catch...

There is a known issue with the FirefoxDriver 2.45, see https://code.google.com/p/selenium/issues/detail?id=8551 Until it gets fixed the workaround is to downgrade Firefox & selenium. BTW: Don't forget to star this issue at google code! Maybe it will help to speed up the fix ;-)...

How to run them from jenkins after success build ? - You can add a trigger to your selenium job so it runs after the build job runs successfully To answer your question accurately, I need to know whether you are planning in running selenium tests in jenkins box... Assuming...

You want to use an ITestListener (or more practically, a TestListener). The official overview is: http://testng.org/doc/documentation-main.html#testng-listeners and the Javadoc is http://testng.org/javadocs/org/testng/ITestListener.html To save you some time, you can extend a TestListenerAdapter, which will @Override all of the methods for you (so you only have to use the @Overrides you need)....

yes its possible to unit test WCF services. The options are: create classes which do all of the work which are separate from the WCF service. Unit test these classes in isolation. Make your service a thin wrapper which calls these classes. test directly with the WCF service class without...

As was mentioned in other replies this was mainly an issue with identification. I cannot explain why things happened the way they did but my suspicions on the WebButton type being 'Submit' had some grounds. Essentially I used the object spy again to pick out the buttons in question and...

Looks like you're running the file with wrong interpreter. You're using JScript, which is a Microsoft language. Bender is a JavaScript application and is designed to be ran by NodeJS interpreter. Make sure that you have NodeJS installed as mentioned in Setting up Bender.js, then use command line to run...

Spock uses AST transforms to wire in the functionality for each test label (when, expect, etc); they may not run the transformations on the cleanup method. They are either not expecting or not encouraging assertions in cleanup, so that code may run but not actually assert anything. You can get...

I think the jre being used by jnlp application should be enabled for RFT to be able to recognize the controls. If JRE is enabled then it does not really matter if the application is jnlp or standalone.

I finally figured out what was going on and wanted to keep anyone else from spinning their wheels like I did. In the <properties> tag at the head of the POM, someone had added a property that read <skipITs>true</skipITs>. There were no integration tests previously, so the property was useless....

Rspec's be_valid expectation essentially just calls valid? on the model, and as such only tests ActiveRecord validations. However, I believe that FactoryGirl's lint method will not only create the model but save it as well and as such tests both the ActiveRecord validations and any database-level validations (that aren't already...

In ClearCase, should I create a project for TestAutomationCommon and then one for each application? The main one I am concerned with, is TestAutomationCommon because multiple projects will share this. No, you create one per Application, with an integration stream including everything that App needs to work with. If...

The root of my problem is really simple, however annoying and this is not the first I'm looking for when I experience issue. The browsers I use for test have different Browser Mode and Document Mode settings. That one where the tests failed had "Browser Mode: IE 10 Compatibility Mode"...

Ok problem solved. I've used GetRoProperty instead of GetToProperty and modified the value in the brackets after WebElement from "name:=Results List OK" to "name:=Results List OK.*" Thanks to gigatropolis for the useful tips (I upvoted your answer) but it was only half the solution :)...

The problem is you mistook the calendar widget as new window and automated accordingly, which resulted in the element not found, rightly suspected by @alecxe Please try the below code and see if it works out for you.: WebDriver driver=new FirefoxDriver(); driver.manage().window().maximize(); driver.manage().timeouts().implicitlyWait(20, TimeUnit.SECONDS); //Navigating to the site driver.get("http://www.lufthansa.com/online/portal/lh/us/homepage"); //Clicking...

I would change the program to accept the string to reverse as a command line argument and then print the reversed string as an output. Then, use a bash script to compare the output of the program against expected output. int main(int argc, char* argv[]){ if ( argc != 2...

You can add a .codeclonesettings file to the project to specify exclusions. See the To exclude specific files or methods from the analysis section at https://msdn.microsoft.com/en-us/library/hh205279.aspx?f=255&MSPPError=-2147217396 for details.

I think I'd go with this: fieldnames = [ 'field%s' % (i, ) for i in range(1, 11) ] for part in parts: existing_part = Part.objects.get(pk=part.pk) for fn in fieldnames: self.assertEqual(getattr(existing_part, fn), getattr(part, fn), "Problem in part %s field %s" % (part.pk, fn)) Makes it easier to understand the problem...

You can achieve this by installing a continuous integration server, which will monitor your version control system, run the tests every time you commit code, and send the notifications according to your configuration (for example, by sending an email to your boss if that's what you need). Popular continuous integration...

Rather than checking if the page is refreshed or not, you should instead expect that it is not and that a certain error message or field highlighting or something is applied to the current page. When in an error state, the input fields probably get given an extra class, or...

You could use one of the following: If possible use an in memmory database like hsqldb, which you can re-create or setup suitably for each TestSuite/TestCase If the methods under test are transactional, run the test case with spring junit rollback true If you cannot use 1 or 2, you...

You have to understand core of your application, how it populates data in drop down, how it searches the query. That'd help you to prepare test properly. For an instance if you select property type as plot then it disables the bedrooms drop-down without knowing about city you have selected.So...

What you're trying to do is a remote hook: update is the one you need. You just have to write a script that's running your test against the repository (or the diff) and return a non-zero code if something sounds wrong for you. More informations here : http://git-scm.com/book/be/v2/Customizing-Git-Git-Hooks (on the...

By default variables are string in Robot. So your first two statements are assigning strings like "xx,yy" to your vars. Then "evaluate" just execute your statement as Python would do. So, adding your two strings with commas will produce a list: $ python >>> 1,2+3,4 (1, 5, 4) So you...

Using SAP Script Recorder One way of getting the function code is to record the action with the SAP Script Recording and Playback (screenshot in German). Open the recorded script in Notepad and find the action session.findById(...).selectContextMenuItem "DELETE_RELATION" "DELETE_RELATION" is the function code you're looking for. Using Silk4J Context menus...

As far as Selenium is concerned, there is no direct facility given by Selenium to connect with any database to check any stored value. To check the saved value you have to connect to databases depending on used db like mysql, oracle etc... you have to use supported api to...

Grunt-contrib-watch makes you to do some task when the inspected file has changed. grunt-crontab can let you do some task at specific time, just like crontab. e.g in grunt setting: grunt-crontab example. { "jobs" : [ { "command": YOUR COMMAND, "schedule": "0 1 * * *", //Every day's 1:00...

Yes, by using property verification you can. E.g. MainForm.VerifyProperty("BackColor", Color.Red); There is an example available at the tafx features pages; How To Accessing properties and methods in the AUT....

From the testability point of view, it's always better to abstract the error logging into a class. If you make direct calls to error_log() you will have difficulties checking the calls made. If you can't refactor your code and use a class for logging errors, you could try setting a...

When you run ctest you can give it a regular expression to choose what tests to run. So you can name the tests in your CMakeLists file according to a pattern which supports this: set(functional_tests "test1" "test2" "test3") set(unit_tests "test1" "test2" "test3") FOREACH(test ${functional_tests}) ADD_TEST(NAME functional_${test} COMMAND f_test.sh ${test}) ENDFOREACH()...

I had a similar 'general' question and posted on the dba stackexchange (http://dba.stackexchange.com/), here and the code review. Here and the code review flagged the question as not being qualified for the site's intentions. However, the people of the dba stack exchange were helpful. You may want to post this...

Within our application's GUI, we have a div html element that behaves as an invisible loading screen, we needed to wait for it to Not exist anymore before we can click the button. For the test code that uses the Selenium 2.44.0's Firefox driver, the Wait object can wait until...

To answer my own question after doing some reasearch and trial and error: Yes, this is a one off command. We don't add it into build config. Selenium Hub and nodes should get started by the scripts I mentioned in the question. You need to login to eaxh box and...

I'd suggest providing a command line argument that your selenium scripts can reference. This argument can contain the the environment ip address you wish to run your tests against. Or another possible solution would to have a property file included in your selenium project that contains environments you use for...

I'd refactor your code. You've already got the Id of the row in your HTML, so let's use that. The TestBuilder tends to make things a bit more difficult to read and includes too many properties to make searching efficient or meaningful. So, your .uitest file has two sub classes:...

I was also using webdriver.io and it looks like documentation is a bit wrong. You can access frames: 1) via it's number on the page. For example the first frame met in HTML DOM is client.frame(0), second client.frame(1) etc 2) via name attribute: <frame name="test"></frame> client.frame('test') 3) find the element...

This is the problem: MyServiceClient msc = new MyServiceClient(); This creates a tight coupling between ArticleViewModel and MyServiceClient. In order to unit test just ArticleViewModel this dependency would need to be mocked. If there's an IMyServiceClient then you'd supply that to the class: public ArticleViewModel { private IMyServiceClient ServiceClient {...

Chrome has command line flags for skipping get getUserMedia permission as well as using fake devices: --use-fake-ui-for-media-stream (skips GUM permission prompt) --use-fake-device-for-media-stream (uses a fake device) Check http://blog.andyet.com/2014/09/29/testing-webrtc-applications, http://googletesting.blogspot.se/2014/08/chrome-firefox-webrtc-interop-test-pt-1.html for background information If you want to click buttons, the standard tool for this is selenium. If you prefer Javascript to...

In TestComplete tests, you can move windows by using the Position method. You can calculate the centered position of a window based on the desktop resolution (Sys.Desktop.Width and Sys.Desktop.Height) and the window size (.Width and .Height): var wnd = Sys.Process("notepad").Window("Notepad"); // Replace with your window reference var x = (Sys.Desktop.Width...

Never put code in a .Designer.cs unless you don't care about it being randomly lost. In this situation what I would normally do is copy the code from the autogenerated DoLogin and make my own method inside UIMap.cs (not UIMap.Designer.cs) that had the custom steps. public partial class UIMap {...