May 2012
3 posts
1 tag
jQuery Deferred at HTML5 Meetup →
I gave recently a short presentation about jQuery Deferred at HTML5 meetup. Here is the link to the presentation itself made with Prezi.
4 tags
Hacker Says
Today is a special day, because Hacker Says - the micro-site created with the help of my friend Andri Möll - got released! Wohoo!
It has interesting, funny and important quotes which apply to software development, programming and life in general. And that all is available for viewing in three different themes!
Here’s a preview of Hacker Says using Sepia theme:
Backend has been written...
April 2012
2 posts
2 tags
Stupidity Of Usability
Usability is one of the most required features of any website or product. If there’s no usability then there’s no product. In this short post i’m showing lack of usability on one of the most popular websites. I’m not gonna mention which website i’m talking about - i’m pretty sure that you won’t figure it out yourself either ;)
Let’s Start!
I...
March 2012
1 post
February 2012
1 post
January 2012
1 post
1 tag
December 2011
1 post
November 2011
5 posts
1 tag
Speedup Ruby 1.9.3 On Windows
Ruby is a great programming language, but unfortunately it does have some problems when using on Windows. One of it’s biggest drawbacks is it’s slowness when loading files. This is also slower than it ought to be on Unix platforms, but not as slow as on Windows. Thankfully there is some work going on to make it faster in future versions. It’s already possible to make it faster...
4 tags
Awesome Page Objects In Testing
I mentioned page objects in the post about WatirSplash 2. In this post i’m gonna explain what these things exactly are and how to use them.
What Is A Page?
When it comes to automated testing then the page is really nothing else than the page user sees when visiting the website. Any meaningful page consists of different components some of which just show information (e.g. text) others...
October 2011
3 posts
3 tags
Facebook, Watir And Testing
I’ve known some time now that Facebook has been using Watir as their integration testing tool. Hell, there’s even a Facebook logo on the main page of watir.com. But today was a special day because i had to read one article about Facebook moving away from Watir.
Confusions
Since i’m one of the few core developers of Watir then this article made me notice statements which...
September 2011
2 posts
5 tags
Fighting Against Gem Hell
There is a term called DLL Hell which in my opinion exists also in the Ruby community with the different name - Gem Hell. This potential problem exists when dependencies for your project and/or libraries are not managed properly.
I’ve written in the post WatirSplash 2 about loading all the dependencies with the help of the Bundler, which helps to organize the dependencies in a sanely way...
Anonymous asked: I have been using the screenshot to obtain IE screen captures. This works well when have a remote desktop session to the IE virtual machine. However, I notice that the capture is a black screen when there is no remote desktop session even though the user session still exists.
August 2011
1 post
3 tags
WatirSplash 2
WatirSplash 2 has been released already some time ago, but i haven’t covered the nice things which came with it. This situation will be improved with the following posts.
New Features
The biggest changes in WatirSplash 2 compared to version 1.x are:
Loading all dependencies with the help of Bundler.
Fixed support for Ruby 1.9.
Introduced so called Page Objects.
Removed cumbersome...
July 2011
1 post
June 2011
1 post
Viva la RAutomation
Watir 1.9.0 got recently released. One of the biggest changes in that version, addition to the support for IE9, is a replacement of AutoIt with RAutomation! This means that the next time you’re installing Watir, you will lose all the functionality of AutoIt automatically. If you used it somewhere specifically to do something, then this post will try to help you to make the upgrade process...
March 2011
1 post
4 tags
WatirSplash With Different Browsers
WatirSplash supported only Windows operating system and IE browser to perform browser based user interface testing. The reason behind that restriction was the usage of Watir framework, which by design is Windows-specific and controls Internet Explorer. Using that browser to test is usually great because most of the developers (including myself) are not using IE during their development time and...
January 2011
1 post
4 tags
Autotesting With Doom-Guy
This post is inspired by one of the over-3-year-old-posts about using Autotest with Growl to show nice notifications about passing and failing tests.
Doom-Guy is here!
I’ve created a small gem for you to get the same helper for your testing needs. It is called autotest-doom which works with RSpec. Read below for installation and configuration instructions.
This is how it looks...
December 2010
2 posts
3 tags
Win32-Screenshot - From Cradle To ...
Win32-Screenshot is a library in Ruby for capturing screenshots on the Windows operating system. In this post i’m gonna write about the history of this gem since it just made it to the version 1.0.0 and i find that it deserves some extra attention due to the changes it has gone through.
Pre-Historic Times
The gem was originally created by Aslak Hellesøy, now a lead developer of the...
3 tags
Automating Windows and Their Controls With Ruby
Update: added part about handling popups.
How would you automate windows and their controls like button and text fields if you had to? How would you do that in Ruby? I guess you wouldn’t. At least not in any user-friendly way.
Until now. I’ve created a Ruby library called RAutomation which allows you to control windows, retrieve different kind of information about them, fill...
November 2010
2 posts
3 tags
How to Use Multiple Formatters in RSpec 2
Update: The issue below is now solved and it is possible to use multiple formatters with RSpec 2. Refer to it’s documentation how to do that.
I’ve started recently to upgrade WatirSplash to use RSpec 2. I thought that it will be as easy as walking in the park. I was wrong. As it turned out then i’m using RSpec unconventionally. This has caused me to create 6 brand new issues...
3 tags
Testing webpages with JavaScript popups correctly
Usually when a JavaScript dialog pops up at some webpage then there is a highly possibility that it shouldn’t be there in the first place. It adds just more inconvenience to any user when needing to perform an additional click to get rid of some pointless message. If possible then solve the problem by removing those pointless usability mishaps altogether!
If there indeed exists some...
October 2010
2 posts
3 tags
Debugging and Improving Watir’s click_no_wait...
I’ve written about debugging Watir’s click_no_wait method problems before. This time i’m gonna do it again because starting from Watir 1.6.6 the #click_no_wait method itself has changed along with the way to debug it’s problems.
In this post i’m gonna also write more about the inner-workings of #click_no_wait and the changes made to it in Watir 1.6.6.
There...
3 tags
About the Past, Present and Future
I’ve applied a complete makeov… err facelift to this blog now! I hope you like it because i do!
In addition to the new look i’ve also removed all the Google Ads (i bet you didn’t even notice them due to AdBlock or just having trained eyes). I wanted to have a little experiment on this blog to see how rich i get. It seems that this is not the way to become rich after...
September 2010
2 posts
5 tags
Wrapping things up and introducing WatirSplash
I’m at the end of writing about most of the ideas i’ve got during the usage of Watir and RSpec in 3+ years and how to use them together for browser based user interface testing. Here is the list of posts from the oldest to the newest on that topic:
Basic Example of Using Watir and RSpec
The Beginning of Watir’s RSpec HTML Formatter
We Need More to be Shown in The Reports?!
...
3 tags
Writing less code in Watir/RSpec specs, part III
If you’ve not read first and second part of these series already then please do so now before continuing.
In this post i’m going to demonstrate how to get rid of accessing too much @browser variable within specs. Consider the following typical RSpec example when using Watir:
In this short example @browser variable is already used four times! Think of some real example and...
August 2010
3 posts
3 tags
Writing less code in Watir/RSpec specs, part II
In the first post of the series “Writing less code in Watir/RSpec specs” i’ve brought up a list of repetitions in the specs when writing user interface based tests with Watir (or something similar). The list itself was this:
Watir, RSpec and another libraries’ require statements
Opening and closing the browser in before and after :all blocks
include statements for helper...
5 tags
Me, myself and... err... ME?!
I’ve managed to end up in a Watir’s Podcast dedicated to me, held by Watir’s community manager Željko Filipin. You can hear me kind of talking from here! Sorry for the not-so-good-english:( But i had good intentions at least!
Feel free to ask questions in comments section or contact me in some other way :)
You can also follow me on Twitter to know when i’m posting some...
3 tags
Writing less code in Watir/RSpec specs
It’s been quite awhile since i last wrote something about using Watir and RSpec, but that doesn’t mean that i’ve forgotten the topic altogether. No, i haven’t and i have a decent backlog about the topics i’m going to write.
If you look at the current specs then there are some things which seem to repeat in each spec:
Watir, RSpec and another libraries’...
July 2010
1 post
3 tags
Git reference by GitHub team →
June 2010
1 post
4 tags
How (not) to validate phone numbers
I haven’t shown any signs of life in here for some time now. That’s because i have been doing great things. Honestly!
One of these things is a current software project i’m working on. I had to fix a bug related with user entering his phone number on his contact information page.
After some digging i’ve found the place where phone number validation was done and how was...
March 2010
6 posts
3 tags
Getting rid of two problems
I’m on my posting spree. In this post i’m going to try to solve the problems i brought up in my earlier post called “Getting rid of global variables”. Solution for problem #1
First problem was the problem where i would like to run my specs without using my formatter. Currently it is not possible because specs are using some methods from WatirHtmlFormatter. There are some...
3 tags
Using modules and methods within specs
I’m pretty sure that by now you have been thinking along the lines - “Oh, wait! There’s going to be a lot of code duplication when creating more than one spec file”. That is not good at all because it causes more pain when trying to maintain your code. RSpec is built to be able to practice DRY principles. So, let’s see from the current spec file, what will be needed...
2 tags
3 tags
Getting rid of global variables
As I promised in two of my earlier posts - “The beginning of Watir’s RSpec html formatter” and “We need more to be shown in the reports?!” - i will show how to get rid of the 2 global variables which are in use so far:
$browser - it is used to store Watir::Browser instance and it’s global because it is needed in RSpec’s WatirHtmlFormatter class for...
2 tags
February 2010
3 posts
Floating point arithmetics in 19 programming...
Update: It seems that there has been some confusions about the results. I’m reminding that you can click on each programming language name to edit the source and see the running results for yourself! But since there is only two type of results - false & true until Pascal and false & false for others, then I wouldn’t bother much.
Update #2: There has been mentioned in the...
5 tags
Capturing JavaScript errors with Watir
There has been few times topics about capturing JavaScript errors during the test. I’m pretty sure that you have seen this or some similar picture in your browser bottom toolbar:
This is exactly the moment which needs to be captured. Ideally it would be captured by your tests anyway, because you’d test all the functionality. This means that you’d click some link and fire all...
2 tags
Debugging Watir's click_no_wait method problems
Update: Information in this post applies only to Watir 1.6.5 and older. If you’re using a newer version of Watir (i hope you do), then read this post instead!
There has been alot of problems with Watir’s click_no_wait method. It has been discussed widely in Watir’s Google Group.
This method is used for clicking html elements without waiting for the browser to finish. For...
January 2010
2 posts
3 tags
We need more to be shown in the reports?!
What about all the files created during the spec? It would be great if all the pdf, image and whatever files saved or generated during the specs are accessible directly from the report. With the current formatter, only screenshot and html of the page are saved. But it’s relatively easy to add this functionality to the formatter - we just have to keep track of all the file names, which are...
6 tags
The beginning of Watir's RSpec html formatter
I’ve promised in one of my earlier posts to create a better RSpec formatter for using with Watir. There isn’t anything hard when it comes to creating your own formatters - you just have to extend some of the already existing RSpec formatter’s classes and then add your own functionality to them.
Since I’m interested in HTML reports as the one created in earlier post, then...
December 2009
1 post
1 tag
Blog's GitHub repository
I haven’t made any blog posts some time now due to busy times at school and with holidays, but today i’ve created a git repository at the GitHub to hold the source files which i will create during the blog posts so it will be easy to see the history of the “project” and the differences between each change.
The repository itself is located at...
November 2009
2 posts
6 tags
Basic example of using Watir and RSpec
Watir is a browser automating tool written in Ruby. It has been working mainly with Internet Explorer, but all of Watir’s contributors are working hard to make it fully compatible with Firefox and other browsers. Hell, they’ve just released a version 1.6.5, which aims a lot of Firefox inconsistencies. So, there is Watir (IE), Firewatir (Firefox), ChromeWatir and SafariWatir....