Friday

Software testing growth rate + Malaysian Software Testing Board (MSTB)



Here is proof that software testing is one with a rapid growth rate across the globe!

Demand for software test professionals is increasing around the globe, in line with the rapid growth of global demand for software testing services.

  • Malaysia too is starting to experience a similar phenomenon as the country continues to develop its software testing industry through the Malaysia Software Testing Hub (MSTH) initiative.
  • Being a software test professional requires specialised skills, particularly at the higher-end of the practice where strong domain knowledge also becomes an essential success factor, and being in a highly on-demand vocation, the career can be rewarding.
  • The Malaysian Software Testing Board (MSTB) promote software tester as a viable career among existing software professionals as well as university students in the software engineering and other information technology (IT) fields.
  • A Technavio Insights report, published in 2012 by United Kingdom-based Infiniti Research, had highlighted that the global outsourced software testing service market was growing rapidly and hence, there was a growing demand for skilled labour (in the discipline).
  • However, there is a shortage of such skilled professionals to meet the demand. The report cited that India, for example, was expected to face a shortage of 39,000 to 41,000 skilled workers in the next few years.
  • The current educational system does not meet the required standards and demand of the market.
  • It has become very important for software testing engineers to have comprehensive knowledge of the business domain and thereby have complete understanding of the clients’ businesses.
  • In a strategic move to mitigate this, MSTB has introduced the Q-College Corp (Q-CC) programme which aims to produce industry-ready professional testers, through ‘accelerated industrial grooming’, from among suitable qualified fresh graduates and working professionals in other disciplines but are keen to develop a career in software testing and software quality assurance.
Source: http://www.theborneopost.com/2013/06/27/increasing-demand-for-software-test-professionals/

Thursday

Automate IE without a tool - VBscript




Here is a basic plain  vbscript which I used to automate a daily chore activity.

Option Explicit

strUser = "Ady"
strPwd = "pwd"

Dim objLink , ie , WshShell , colLinks
Dim i , intDay , intOff , intcount , btn, strText, j
Dim strUser , strPwd , hwnd, Wnd, oShell, objImage, objImages , strOut



Sub WaitForLoad(obj)
   Do While ie.Busy
   Loop
  
   Do While obj.readyState <> 4
   Loop
   wscript.sleep(100)
End Sub

'Create ie and shell object
Set ie = WScript.CreateObject("InternetExplorer.Application")
Set WshShell = WScript.CreateObject("WScript.Shell")

'set the ie properties
ie.ToolBar = 1
ie.StatusBar = 1
ie.Width = 1500
ie.Height = 999
ie.Left = 0
ie.Top = 0
ie.Visible = 1

With ie
hwnd = .hwnd
      .Navigate "http://test/default.aspx"
End With

Set oShell = CreateObject("Shell.Application")
For Each Wnd In oShell.Windows
        If hwnd = Wnd.hwnd Then Set ie = Wnd
Next

'wait until the page has loaded before continuing
WaitForLoad(ie)

'Enter the user details
Enter the user details


ie.Document.getElementByID("txtUser").Value = strUser
ie.Document.getElementByID("pwdPass").Value = strPwdw
WaitForLoad(ie)

'Alert Box
WshShell.AppActivate "Main - Windows Internet Explorer"


For i=1 to 10
   wshShell.sendkeys "{TAB}"
   wscript.sleep(200)
Next

ie.Document.getElementsByName("ctl00$ContentPlaceHolder1$btnView").Item(0).Click
wscript.sleep(5000)
ie.Document.All.Item("chkall").click


For Each objLink In colLinks

   ' check text for link
    If InStr(UCase(objLink.innerHTML), "OFF") > 0 Then
   ' navigate to the first match and exit the for...next loop
    intcount = intcount + 1
    If intcount = intOff then
            'ie.Navigate objLink.href
            objLink.click
            Exit For
     End If
     End If
Next
wscript.sleep(2000)msgbox "done"
Set ie = nothing
Set colLinks = nothing
Set WshShell = nothing





Monday

The object invoked has disconnected from its clients Vbscript and internet explorer



Here was a vbscript that was working well and all of a sudden started throwing this vague error - "the object invoked has disconnected from its clients"

After a lot of research here is what I found that might save your day:

Find the handle of the window and re-associate the object with the handle. (This is what will reconnect your ie client back to the object"
Here is the code:

Set ie = WScript.CreateObject("InternetExplorer.Application")
With ie

     hwnd = .hwnd
     .Navigate "http://xyz.com"
End With

Set oShell = CreateObject("Shell.Application")

For Each Wnd In oShell.Windows
       If hwnd = Wnd.hwnd Then Set ie = Wnd
Next

  Happy Coding :)

Thursday

Improve Automation ROI basics



Want to increase the Automation ROI ? Here are bullet points that you can work upon:

Changes in framework architecture: the way BPT tests are created


Maximum utilization of the automated scripts – Increase frequency of test suite runs

Process Integration - automating the entire process can derive significantly greater value

Contextual automation – Use cues like the time of day automation is run, other programs running and their potential impact on system performance, Schedulers and Nightly runs.

I am sure there are other ways , please add comments if there is something that can significantly improve the Automation ROI.

Wednesday

Career in Software Testing



Mostly my posts are technical but off-late I have had a lot of people either fresh grads out of college or experienced developers wanting to move into testing asking me one common question. What is the scope of a career in testing/automation.

My answer:

Software testing is an amazing profession that offers a rewarding and structured career path with clearly defined roles and qualifications. Why?
  1. There is scope for improving the way testing is done in most companies.
  2. More opensource community and many mature testing tools
  3. Every company allocates and adequate amount for testing.
  4. Plenty of jobs and least affected by recession/lay offs.
  5. Salaries are in-par with developers and if you are good its always more than the dev community.
  6. The best part being we are technology independent folks , we fit into any bucket irrespective of our specialization - Manual(Functional)/Automation/Performance/Security.
Roles generally in testing:

Technical Track

Software Test Engineer Tests and critiques software to assure quality and identify potential improvement opportunities and projects.
Software Design Engineer in Test(SDET)Tests and critiques software components and interfaces in more technical depth, writes test programs to assure quality, and develops test tools to increase effectiveness.
Software Test ArchitectIdentifies test design and implementation improvements, runs pilot projects to measure their impact, and drives adoption across various Microsoft product development teams.

Managerial Track

Software Test Lead
Directs and leads a team of test engineers and is responsible for the quality of certain product areas and components.
Software Test Manager
Oversees product testing within a product unit, designs master test plans and schedules, and manages test organization via test leads.
Director, Quality Assurance
Runs the QA organization.


Finally there is lot of knowledge, jobs, smart engineers and good salaries in this field. Do you need any other reason to choose testing as your career?

Tuesday

Firefox profile with Selenium Webdriver



Firefox, like your home page, what toolbars you use, saved passwords and bookmarks are all stored in a special profile folder.

Get webdriver to come up with firebug:

Download the firebug xpi file from mozilla and start the profile as follows:


File ext= new File("firebug-1.8.1.xpi"); FirefoxProfile firefoxProfile = new FirefoxProfile(); firefoxProfile.addExtension(ext); firefoxProfile.setPreference("extensions.firebug.currentVersion", "1.8.1"); // Avoid startup screen firefoxProfile.setPreference(“extensions.firebug.console.enableSites”, true); //enable console

//some more prefs:
firefoxProfile.setPreference( “app.update.enabled”, false);
firefoxProfile.setPreference( “browser.tabs.autoHide”, true);


//use this profile:
DesiredCapabilities capability = DesiredCapabilities.firefox();
capability.setCapability(FirefoxDriver.PROFILE, profile);

 WebDriver driver = new FirefoxDriver(firefoxProfile);  

Enabling features that are disabled by default in Firefox  
FirefoxProfile profile = new FirefoxProfile();
profile
.setEnableNativeEvents(true); 
WebDriver driver = new FirefoxDriver(profile);

Set language in profile
profile.setPreference( "intl.accept_languages", "no,en-us,en" ); 
 
Setting the AssumUntrustedCertificateIssuer of the FirefoxProfile object to false
profile.setAssumeUntrustedCertificateIssuer(false); 
Creating a new profile using the Profile Manager•Close the application and make sure that it is not running in the background.
•Start the Profile Manager
          
 ◦Windows
■Open the Windows “Start” menu, select “Run” (on Windows Vista, use “Start Search” or enable the Run box, as described here) then type and enter one of the following:
firefox.exe -P
or run the Profile Manager
"C:\Program Files\Mozilla Firefox\firefox.exe" -profilemanager


◦Linux
■Open the terminal and execute cd firefox program directory. If you don’t know where firefox is installed, you can always do
locate firefox
■Then execute:
./firefox -profilemanager

◦Mac OS X
■Assuming the program is installed in the “Applications” folder, launch Terminal (“Applications -> Utilities -> Terminal”)
■Enter the command starting with / after the prompt in Terminal:
/Applications/Firefox.app/Contents/MacOS/firefox-bin -profilemanager

To find which profile is really used when Firefox is running, do the following.

From Firefox click Help -> Troubleshooting Information
On the new tab with the title "Troubleshooting Information", click the button "Open Containing Folder"

Monday

Beyond Compare with QTP/VBScript



Scooter's software Beyond Compare with QTP/VBScript:


Public WorkingFolder = "C:\Test"


Public BeyondComparePath = "C:\Program Files\BC3\Beyond Compare 3\BCompare.exe"



Public Function CompareFiles(LeftFile, RightFile, ReportName, ComparisonType)

         CreateBeyondCompareScript
         Set oShell = CreateObject("Wscript.Shell")
         'Select Different Comparasion Type Script
         If LCase(ComparisonType) = "text" Then
                  BeyondCompareScriptPath = WorkingFolder & "BC_Text.txt"
         Else
                  BeyondCompareScriptPath = WorkingFolder & "BC_Data.txt"
         End If

GenerateReportCommand = """" & BeyondComparePath & """ @""" & BeyondCompareScriptPath & """ """ & LeftFile & """ """ & RightFile & """ """ & ReportName & """" & " /closescript /silent"
QuickCompareCommand = """" & BeyondComparePath & """ /qc """ & LeftFile & """ """ & RightFile & """"

'Run to generate Report
oShell.Run GenerateReportCommand, 3, True

'Run to get Exit Code
iErrCode = oShell.Run(QuickCompareCommand, 3, True)
CompareFiles = iErrCode

End Function




Function CreateBeyondCompareScript()

            If Not (oFSO.FileExists(WorkingFolder & "BC_Data.txt")) Then
               Set oFile = oFSO.CreateTextFile(WorkingFolder & "BC_Data.txt", True)
               oFile.WriteLine "data-report layout:InterLeaved &"
               oFile.WriteLine "options:ignore-unimportant,display-all &"
               oFile.WriteLine "output-to:%3 output-options:html-color &"
               oFile.WriteLine "%1 %2"
            End If

           If Not (oFSO.FileExists(WorkingFolder & "BC_Text.txt")) Then
                Set oFile = oFSO.CreateTextFile(WorkingFolder & "BC_Text.txt", True)
                 oFile.WriteLine "text-report layout:InterLeaved &"
                 oFile.WriteLine "options:ignore-unimportant,display-all &"
                 oFile.WriteLine "output-to:%3 output-options:html-color &"
                oFile.WriteLine "%1 %2"
           End If

End Function

ReturnCode = CompareFiles(ProcessedDataSorceFileName, ProcessedFeedFileName, “Report.html”, “data”)

Return code can return below values (from BC help):


0 Success

1 Binary Same

2 Rules-Based Same

11 Binary Difference

12 Similar

13 Rules-Based Difference

14 Conflicts Detected

100 Unknown error

101 Conflicts Detected. Merge output not written.


Thursday

QTP or Selenium / QTP v/s Selenium


Automation ToolQTPSelenium WebDriver
License Cost$9000 for each floating license or $6000 for a node-lock licenseOpen Source
What can be tested?Most windows applications and Web ApplicationsOnly Web
Other tools requiredQuality Center for test managementMostly needs tools like TestNG/Fitnesse/Development tools/Reporting tools and so on
Language VBScriptJava/.NET/PHP/Perl strict programming rules unlike the loose scripting in vbscript
Windows CompatibleOnly WindowsWindows/MAC/UNIX Platforms
Android CompatibleNY
Tester FriendlyYN
Companies Larger firms who can afford the toolSmaller Firms and a few larger ones
Learning RequiredMinimalLoads of tools and Programming skills for JAVA/.NET
Platforms Not very easy when it comes to multiple OS /Browsersselenium grid with a 3rd party grid service like Saucelabs
BooksManyFew good ones for Java and .NET
Open Source FrameworksYJust One
Agile FriendlyYY
What Customers have to say?Most Popular test automation tool if you have a combination of apps to testMost popular open source tool for web apps
What Testers have to say?A tool that has to be on your resumeGood to have especially if you want to work only on web applications
What I have to say?Tool shouldnt matter, it is the automation approach you should be focussing on more!
For Selenium UsersQTP? Its not as bad as you think it is. It does a lot more!
For QTP Users Selenium WebDriver? Its just an API like many others you use in VBScript

Tuesday

Skillset - Automation Tester | Agile | Selenium or QTP





Note: the Skillset category is just to gauge where you stand in terms of the skills required for the role


Yet another interesting test automation profile :


Are you a technical tester? Do you want to work with the best? Are you looking for a challenging and energising role where you can learn? If the answer is yes to all 3 questions read on!


An Automation Tester / Test Automation Specialist is required by a leading and financial systems company in Central London. As a highly successful business they are completely unrivalled in their bespoke financial systems solutions that they provide for the world's most exclusive Investment Banks, Brokerages and Trading companies. My client pride themselves on being one of the most technically astute testing teams in the UK and firmly encourage knowledge sharing amongst it's testing team enabling their consultants to be best they possibly can be. If you are a Technical Automation Tester looking to gain experience at the top end of the financial services market and continue developing your skill set with a great team and exciting business then this is the perfect opportunity!

To begin the successful Automation Tester / Test Automation Specialist with experience of testing tools such as QTP, Selenium, WebDriver, JUnit, JMeter, NUnit or Rational Robot. To utilise these automation tools the successful applicant will have an in-depth knowledge of at least one programming language to build complex test automation frameworks. Desired languages consist of Java, C#, Ruby, Perl or Python and SQL. The successful Automation Tester / Test Automation Specialist will have recently worked in CI (Continuous Integration) projects and have built unit tests.

Other broader skills needed to be a successful applicant includes experience in Agile, Scrum, TDD or BDD development lifecycles as my client works to short sprints and have a great name as an Agile business. Knowledge of Unix, Bash, ksh, Windows, Oracle and SQL is also highly advantageous.

This is a superb opportunity for a skilled Automation Tester to gain experience with a highly respected team and work on fantastic financial services projects.