Ally's a QA

August 23, 2010 - Browser Compatibility Testing

Posted by jstrazzere
http://strazzere.blogspot.com/2010/08/browser-compatibility-testing.html


Any comments on this article?
Email Me

Permanent Link

August 9, 2010 - I'm Voting For SQAForums

Posted by jstrazzere
The Automated Testing Institute is running their 2nd Annual "ATI Automation Honors" competition.

From the ATI website:
The industry's original set of awards dedicated to software test automation is again looking to crown industry leading tools, resources and practitioners with automation's top honor. That means it's time for all of you to get busy! The ATI Automation Honors awards rely on industry practitioners to identify which tools, resources and people are the best, which have the most significant upgrades and/or which are setting the trends that will help to take software test automation to the next level in the coming year.

Last year SQAForums.com won the best software testing website award. This year they are nominated in the "Best Automated Testing Forum" category.

I don't think there's much doubt that SQAForums is the best for supporting virtually every test automation tool that exists. With their individual tool-specific forums, as well as their general automation forums, everyone can find a handy home for helpful hints, tips, in-depth product reviews, and the kind of product support you can't even get from the vendors' sites.

That's why I'm voting for SQAForums. Won't you join me? To vote, go to http://www.automatedtestinginstitute.com/home/index.php?option=com_jforms&view=form&id=10&Itemid=183


Any comments on this article?
Email Me

Permanent Link

2010-Aug-6 - Running Fitnesse with PowerShell - RESTful Tests

Posted by Michael

Previously I noted how I had written my original tests with Fitnesse to use the TestRunner and access Fitnesse in a way that worked, but as I recently discovered is no longer supported.  Oh well, so I update my tests.  Which was necessary anyway, since on the Build Machines where these tests would be run Fitnesse is not going to be running, and if it was I shouldn't need to usurp it for my tests.  So I moved over to using the RESTful method, which I had a hard time with earlier, but now is so insanely simple I wonder why I had a hard time with it before.

 

Without futher ado, here is the RESTful method to run Fitnesse tests.

 

First I set up my variables, I've also added in an archive file now, so I can keep track of my results, the RESTful results are nice so I actually output each test into its own results file, and I make an aggregate to be an archive.  Eventually I will get rid of the individual results and keep the archive around - this also let's me go onto any machine that ran a test and see how things have been going.  The Arrays I have are suites that I set up in Fitnesse to contain my tests, I have one for QA that I would run, and a Smoke suite that is a selected set to verify the build worked.

 

# Get the current directory

Push-Location .

# Variables for the script

# This location should not change, since its the standard checkout location

[string]$fitnesseLocale = "C:\MAIN\trunk\AutomatedTests\Fitnesse\Fitnesse"

[string]$fitnesseJar = "fitnesse.jar"

# Need to get the local machine here, it will be how Fitnesse runs

[string]$serverName = $env:COMPUTERNAME

[string]$portName = "8080"

# These are needed for the CheckFitnessProcess function,

# placing them here

$fitRunning = $false

# Set Java executable to use within PowerShell

$Java = "java.exe"

# Archive file

$archiveFile = "fitnesseArchive.txt"

# Use a Test Array to be able to bundle all the tests

# Tests that are commented out are having issues being run

# Smoke Testing is Development Based

# although its now geared towards checking Login

$smokeArray = ( "SpringsLoginLiteTests" )

# Tests for the QA environment

# although its now geared towards checking page links

$qaArray = ( "SpringsLinkChecks" )

# Tests to check how this script runs, this is a hidden command

# This just validates the Registration Verify Fields

$checkArray = ( "SpringsTest.UserLoginFfTests" )

# Location of the Test Results, this is hardcoded within the SVN structure

# so it should always be available, I am sure there are better ways of doing this

$testResultsDir = "C:\IHI_MAIN\trunk\AutomatedTests\Fitnesse\Fitnesse\testResults"

if (!(Test-Path -path $testResultsDir))

{

  New-Item $testResultsDir -type directory > $null

}

Then I still run my check on whether Fitnesse is running, it doesn't really need to be running anyway; so I decided that since REST only runs as needed then I was going to shut down Fitnesse if it was going.

 

# CheckFitnesseProcess determines if Fitnesse is running, if Fitnesse is not running

# then the script continues. The current test configuration does not require Fitnesse

# to run and does a better job when it's not.

# Adapted from: http://odetocode.com/Blogs/scott/archive/2006/07/17/5330.aspx

function CheckFitnesseProcess {

  param ([string]$AppPoolName="")

  $ProcessId = $null

  if ($AppPoolName.ToUpper() -ne $NOT_PASSED) {

    [string]$filter = $null

    if ((Get-Process java -ErrorAction SilentlyContinue) -ne $null) {

      Get-Process java | ForEach {

      # use WMI API to get process details

      $filter = "Handle='" + $_.Id + "'"

      $wmip = Get-WmiObject Win32_Process -filter $filter

      # CommandLine property has AppPool name; grab name using contains

      if($wmip.CommandLine.contains("fitnesse")) {

        # Uncomment the next line for debugging

        # Write-Host "Found this java process: $wmip.CommandLine `n"

        $fitRunning = $true

        # Saving the Process ID to stop the process later,

        # using a Global as I could not get this work if I declared

        # the variable at the beginning.

        $Global:fitProcess = $_.Id

      }

    }

  }

  if ($fitRunning -eq $false) {

    # All is good

  }

  if ($fitRunning -eq $true) {

    Write-Host "Fitnesse is running, it's best if its not - shutting it down...`n" -ForegroundColor Red

    # Stop the Fitnesse process

    Stop-Process -Id $fitProcess

  }

 }

}

I'm going to skip the Help function, if you need that it should be in my previous post, the important one is the Main function.

 

function main()

{

  # Need to be in the Fitnesse directory to access TestRunner, and

  # the Fitnesse batch file in case Fitnesse needs to be started

  cd $fitnesseLocale

  #Check and see if Fitnesse is running

  CheckFitnesseProcess

  foreach ($test in $testArray)

  {

    # Start the test

    $myDate = Get-Date

    Write-Host "`nRunning $test`n"

    # Build RESTful URL

    $testLink = $test +"?" + $testType +"&format=text"

    # Get the output from TestRunner so we can scrape it for test passes and fails

    $testResults = & $Java "-jar" "$fitnesseJar" "-c" "$testLink"

    Write-Host "Completed $test`n"

    # Write-Host "Test Results..."

    # Scan through the output, then display the results

    # Dump $testResults out to a File

    $testFile = $test + $myDate.Day + $myDate.Month + $myDate.Year + $myDate.Hour + $myDate.Minute + ".txt"

    $testResults | Out-File "$testResultsDir\$testFile"

    # Print out date to an archive file

    $testDate = "Last run time: " + $myDate.Day + "/" + $myDate.Month + "/" + $myDate.Year + " at " + $myDate.Hour + ":" + $myDate.Minute

    $testDate >> "$testResultsDir\$archiveFile"

    foreach ($line in $testResults)

      {

      if ($line -match "\A\.\s"){

        # This is a Pass

        Write-Host $line -ForegroundColor Green

        # Output to archive file

        $line >> "$testResultsDir\$archiveFile"

      }

      if ($line -match "\AX\s") {

        # This is an Exception, a warning but not a Failure

        Write-Host $line -ForegroundColor Yellow

        # Output to archive file

        $line >>

Comments (0) :: Permanent Link

July 29, 2010 - Memorable Summer Jobs

Posted by jstrazzere
I was listening to NPR's All Things Considered on the way home from work last evening. They've been running a series called "Summer Jobs", and they have had some really unusual ones. So I thought I'd share one of my summer jobs, too.

http://strazzere.blogspot.com/2010/07/memorable-summer-jobs.html


Any comments on this article?
Email Me

Permanent Link

July 26, 2010 - Strange New Planet Discovered

Posted by jstrazzere
I just discovered a strange new planet! Go here to find out more: http://strazzere.blogspot.com/2010/07/strange-new-planet-found.html


Any comments on this article?
Email Me

Permanent Link

<- Last Page :: Next Page ->

About Me

Here I share my experiences and thoughts as a QA engineer, and a place to put my notes.

Search This Blog

Categories

My thinkings
My knowledge base
My tools

Links

Home
View my profile
Archives
Friends
Email Me

Friends

whollymindless
strazzerj
syed1982
mferris
ukkuru
michaeljf
agvasqa
priyabala
srini847
spikyone
naba123
Blog Widget by LinkWithin