Coding paradigm: line by line all my opinions are belong to me

I like to code and I like the feeling of code lines coming out of my fingertips. I try to build the simplest and most usable solutions to make awesome.

I live and work in Riga, Latvia and spend my days making kick ass things.

github curriculum vitae linkedin mail devternity

«Archive» · «Tags»

Atlassian Plugin SDK - how to provide optional selenium tests

You probably are familiar with one of the most popular web UI testing tool - Selenium and it’s most famous tool Selenium IDE.

I don't want to read all this, give me the code
You could find all the code you need on github.
Sorry for not embedding all the code in the article. That way the article becomes clumsy unreadable monster. If anyone could recommend me some collapsable/expandable solution - I would appreciate it a lot.
Why do I need to bother with yet-another-testing-tool? The main advantages or features of the tools are (imo):
  • real UI behavior testing - tests are run inside the real browser and will fire/use real end-user key, mouse, etc events
  • ability to export the test in whole bunch of programming languages (java, python, ruby etc ...)
  • ability to run tests on multiple target web-drivers (firefox, internet explorer, etc ..)
  • Selenium IDE (mentioned earlier) is really nice tool which allows to create simple tests cases very fast, in few minutes or even seconds, literally
  • basically the only way to automate difficult Ajax/RIA component testing on different target environments; other httpUnit like approaches are not good enough
How could I automate that? Selenium has child project - Selenium Remote Control which could be used. Quote and image from Selenium Remote Control site:
Selenium RC comes in two parts.
  1. A server which automatically launches and kills browsers, and acts as a HTTP proxy for web requests from them.
  2. Client libraries for your favorite computer language.
Lucky to us, selenium has maven artifacts available to be used to plug-in into Atlassian PDK build procedure. Goals:
  1. make this optional (enabled by default) option
  2. selenium-rc server side should be forked before integration tests will be executed
  3. selenium-rc client side tests should be executed as part of the integration test suite
  4. selenium-rc should be revoked upon integration-test completion
  1. is achieved by default maven profile (activated by !property)
  2. is achieved by maven - specifying selenium-rc start-server goal to be run on pre-integration-test phase
  3. to achieve this please refer to Atlassian article - Writing Integration Tests. Basically that means - you should put your code inside src/test/java/it/ folder and specifying proper file.
  4. is achieved by maven - specifying that selenium-rc stop-server goal should be executed on post-integration-test phase.
To get pom.xml file snippet - see this pom.xml gist How to check: execute atlas-integration-test command from the project home folder.
Read more

#oldstuff - 3. Mini seminar 2 - Mylyn

Check out this SlideShare Presentation:

Read more

#oldstuff - 2. Design patterns. part #2

Check out SlideShare Presentation:

2. Design patterns. part #2 from Leonid Maslov
Read more

#oldstuff - 1. Mini seminar intro

Check out this SlideShare Presentation:

1. Mini seminar intro from Leonid Maslov
Read more

HowTo: Reusing JIRA gadgets on the issue operations

Hi everybody,

Read more