Monday, 1 March 2010

VS2010 - Test Impact, one giant leap for testkind!

Hi there, finally got round to another blog article; this one is in the form of a vlog.

In the agile world, understanding the impact of code churn is vital, using the test impact collector in VS2010 testers can be told which manual and automated tests need to be rerun, I've put together this demo to show it working.

Soo...full screen the video, sit back, enjoy and please give us your feedack!



Please note the full screen button is located next to the progress bar and volume controls whilst hovering the cursor at the bottom of the video.

The vlog can also be viewed at our website

Thursday, 25 February 2010

nFocus to facilitate Intellect Software Testing Strategy Workshop: London, April 2010

I thought this may be of interest to some of our community.

"Reduce risk and increase your confidence that the quality of your software product is at a known quantifiable level."

This course takes you through the key aspects of forming a test policy and strategy allowing you to establish your weak and strong points and a plan of action. In essence a process of “getting to know what you don’t know” so that informed decisions can be taken on appropriate investment in testing.

The workshop approach allows interaction between attendees establishing common issues and their solutions. The class will be run as a sequence of short talks each followed by an interactive session allowing delegates to focus on areas of common concern. In addition to class material the key discussion points from the day will also be documented and circulated to the attendees.

Want more information? Please click here.

Wednesday, 17 February 2010

New video blog post due shortly...

Sorry we have been so quiet on the blog front at nFocus recently... it has been a really busy period! We hope to have a new video blog post on here shortly, along with a series of articles around VS2010, so please watch this space!

Thank you for bearing with us,

The nFocus team.

Tuesday, 19 January 2010

It’s testing Jim but not as we know it...

This is a short post to let you know nFocus and Microsoft will be facilitating a session at this year's Test Management Summit (27/01/2010).

The challenges of applying test discipline in the world of agile projects continues to be problematic. The session will explore how tightly integrating testing into the application lifecycle can protect the reputation of the business. This approach will be demonstrated using a state of the art Application Lifecycle Management tool which supports development and testing in a dynamic changing environment.

For more information and booking details click here.

Friday, 11 December 2009

Share and Share alike in VS2010 "MSTLM"

Hi there, finally got round to writing another blog and with this one, I am really excited. Recently, I have been spending alot of time getting to know Visual Studio 2010 and what this new release means to us testers. Well, here's the thing, VS2010 is great for testers, finally Microsoft produce a tool that I want to use as a tester. There are many things that are great about VS2010 like Test Planning, Manual Testing, Action Recordings, CodedUI automated tests, IntelliTrace, Test Impact collector and Rich "actionable" bugs to name but a few. We also have a dedicated UI - Microsoft Test and Lab Manager(MSTLM)! I can see that I am going to be getting busy writing articles on all of these subjects but for today, I just want to talk about the feature called "Shared steps".
All too often the lowly manual test is neglected but this is not the case in VS2010, the Test work item now has the ability to record execution information against test steps, which is made all the more powerful with the implementation of shared steps. By way of an example, if your SUT is an online fashion and beauty retail system and many of your tests actually transact all the way through including a purchase using a visa credit card, then you may well have a candidate for a shared step - PayByCreditCard. In the MSTLM (Testing Center) you would go to the "Organize" Tab then the "Share Steps Manager"
Here we can see our shared step called "PayByCreditCard", so digging into the detail we can have a look at how the shared step is constructed:
We can see that the shared step is made up of a sequence of actions with their expected results, of interest here is the ability to include attachments with steps, by way of an example, we can see the step that tells the user executing the share step to "click on the radio button underneath the visa image". It could be that we have a Visa image and a Visa Debit image and a good way to distinguish would be to have a snapshot of what the image should look like. Also here we can see the use of parameters and default parameter values. As you can see we have a @enddate parameter and the calling test would be asked to use the value 09/12 for this step (unless of course it is overridden in the calling test).

So now, all we need to do is reference this shared step in an actual test:

In this step whilst editing the test case we can use the "Insert shared steps" button to reference our shared step "PayByCreditCard" that we created earlier, see also how it brings with it all of the parameters from the shared steps. This allows the user to override the default parameter values in the shared steps or create multiple iterations as you can see, here we have used a different credit card number 8888888888888888 for this test. Now as we use the TestRunner to execute the test, we are prompted for the values that we specified at the test level:


But here is the great news, the test runner supports "Action Recording" which is an elementary interface on the automation engine. If we use this to record the shared step, then for all subsequent tests that use the same shared step, we can play them back in a Fast Forward style. My experience of this feature is, so long as you pay good attention to what the engine is recording, then this will save you hours of manual testing. Pure genius!

Tuesday, 1 December 2009

Video Introduction to Google Wave

This is a really neat video which looks at 15 features of Google Wave...Enjoy.

Best viewed in full screen mode.


The Rosy translation robot is a really interesting and useful feature! More to follow.

Friday, 13 November 2009

Manual Intervention in an Automated Test

Supporting Files
- nFocusMessageBox.zip

You may be wondering why you would want to add manual intervention to an automated test run, I used to have the same thoughts as you, but I have seen the benefits of the approach. Before we start it is important to understand that normally any manual intervention in an automated test run is a bad idea, for one thing the tests will not run.

First let’s explore where this approach is useful:

  • Manual verification: You might have to verify objects that cannot be mapped, or are difficult to test, eg. Flash, Silverlight.
  • External processing: In order to automate the end to end process a batch process might have to be executed. If you can use Axe to execute the batch process great.
  • Get around CAPTCHA.

I have used manual verification successfully on a project a few years ago to verify the look and feel of a website, and I currently need to use external processing to test an ETL process.

For those of you that do not know what an ETL process is, it is basically Extract, Transform and Load. Testers do that all the time trying to set up test data.

The high level testing steps are as follows:

1. Stop the ETL process and clear down the system

2. Load all data into the source system using Axe

3. Start the ETL process

4. Verify the data in the target system using Axe

5. Stop the ETL process

6. Edit the source data

7. Restart the ETL process

8. Verify the data in the target system using Axe

9. Stop the ETL process

10. Delete the source test data

11. Restart the ETL process

12. Verify that the data has been marked as deleted on the target environment

I know that some of you are asking why we cannot use Axe to stop and start the ETL process. The answer is “Yes we can, but this is the first implementation of the ETL process and we have now ironed out the bugs”. To change the manual steps to automated steps using Axe is really easy and can be done later.

Enough ramblings, lets get to how we implement the functionality. I am going to assume that you have a project library file and ActionMap. As always you can always download a working zip file from here and unzip to your C:\ drive.

We are going to implement parts of the .NET MessageBox class, specifically a standard dialog with an OK button, and a dialog with Yes and No buttons. The latter can be used for manual verification.

1. Add a reference to System.Windows.Forms in the __testInit section of the project ActionMap: using System.Windows.Forms

2. Add the following method to your project library file:

public static int YesNoMessageBox(AxeMainAPI axe, string message, string title, DialogResult expected)

{

int result;

DialogResult actual = MessageBox.Show(message, title, MessageBoxButtons.YesNo);

if (actual == expected)

{

result = 0;

}

else

{

result = 1;

}

return axe.StepValidate(expected.ToString(), actual.ToString(), result);

}

3. Hook up the MessageBox class and custom method to the ActionMap as follows:

Table 1

4. Add the following to the ObjectMap:

Table2

5. Next step, create a Subtest page for the mapped objects.

As you can see from the Actions, the MsgBoxOk class is overloaded with the possibility to have a title on your dialog box, eg: set( MessageBox title). The MessageBox text is read from the data column in the test step.

The Expected parameter for the MsgBoxYesNo Action can be one of the following:

  • DialogResult.Yes, eg: set(nFocus MessageBox Example, DialogResult.Yes)
  • DialogResult.No, eg: set(nFocus MessageBox Example, DialogResult.No)

As in the MsgBoxOk class the MessageBox text is read from the data column.

6. Last step is to download the example and try it out.

I hope that you found the blog interesting and understand the potential to have manual intervention in an automated test.

Marc Maurhofer