Where he blogs about his eclipse musings
Code Coverage And Functional Tests
I am often asked this rather perilous question:
How do I view code coverage for my functional tests?
Short answer:
Here’s how…. However, use it only for figuring out what functionality is not covered, not as a workaround for not having enough unit and integrations.
Having to use functional tests to determine percentage of code coverage is IMO a bad smell, avoid as much as possible.
No trackbacks yet.
Tell, Don’t Ask – Part 2
September 4, 2009 - 8:16 am
Tags: clean-code, eclipse, mocks, programming
Posted in Uncategorized | 5 comments
Objects exposing behavior, not state
Controlling complexity of your codebase by limiting what state your objects expose
The more objects that can see and change states on other objects, the more complex your system. Objects returning a boolean mean that someone calling that method will use an if branch, returning an integer would mean someone using if/else [...]
Tell, Don’t Ask – Part 1
September 4, 2009 - 8:10 am
Tags: clean-code, eclipse, mocks, programming
Posted in Uncategorized | 4 comments
I spend more time reading code than writing it. I therefore like code that is readable. Rarely do I like to read code that is verbose and does too much orchestration in order to do something that is orthognal to what I’m looking for.
Code is easier to read and maintain when objects are written in [...]
GEF Support for SWTBot
August 4, 2009 - 7:50 am
Tags: eclipse, gef, swtbot
Posted in Uncategorized | No comments
A long pending request from swtbot users has been support for GEF. The SWTBot4GEF project was created as a sandbox to see how feasible things were in the GEF world.
Mariot Chauvin recently polished the initial contribution from David Green and released a version 0.1 of the gef support. We’re working towards integrating this as part [...]
SWTBot Getting Started Video Tutorials
July 15, 2009 - 12:51 am
Tags: eclipse, swtbot
Posted in Uncategorized | 4 comments
Getting started with SWTBot is a unique experience for a lot of users, and myself. Unlike most other projects hosted at eclipse.org, it’s a UI testing tool written for primarily for testers to be able to write automated tests.
In this regard the users of swtbot are a bit special. Most of them understand testing and [...]
Just upgraded my blog to a newer wordpress…
July 15, 2009 - 12:04 am
Tags: eclipse
Posted in Uncategorized | No comments
… and just wanted to see all the parts are still moving.
Eclipsetasy! Time to throw away the dope…
June 19, 2009 - 11:40 am
Tags: eclipse, swtbot
Posted in eclipse | No comments
… and move to newer dope…
I just realized that I had about 58 eclipse SDKs downloaded on my hard drive and 22 instances of different versions of eclipse. That was a whooping 9GB for the sdk downloads and 6.5GB for the extracted versions. Time to move to newer dope
Similar was the case on [...]
Eclipse Galileo DemoCamp Pune
June 8, 2009 - 8:37 am
Tags: democamp, eclipse, galileo
Posted in General | No comments
A reminder to those following Planet Eclipse that there’s a Galileo DemoCamp in Pune on Saturday, 13th June 2009. Sign up on the wiki page so that the ThoughtWorks Pune office is stuffed with enough food to feed you
An Eclipse DemoCamp is a congregation of Eclipse enthusiasts to meet up and demo what [...]
Eclipse Updates slowing you down ?
June 3, 2009 - 3:56 pm
Tags: eclipse, p2
Posted in General | No comments
There’s a joke about maven downloading half the internet. Apparently p2 talks to the other half maven does not download.
Earlier you’d go get a coffee every time you clicked the eclipse update manager. With the eclipse servers taking a beating and download speeds really going slow you better grab lunch.
But wait there’s another nifty “hack”: [...]
Announcing a new release of SWTBot
May 29, 2009 - 6:04 pm
Tags: eclipse, swt, swtbot
Posted in Java, Open Source, eclipse | No comments
You can download the latest and greatest from the SWTBot download page.
A listing of some of the new features available:
Bug 263036 – SWTBot finally has an icon that was missing since two years!
Bug 269919 – Added support for toggle buttons
Bug 271246 – Better support for handling editors. This should serve as a good start towards [...]
Java and Unicode monday morning blues
May 25, 2009 - 3:33 pm
Tags: eclipse, Java
Posted in Java, eclipse | No comments
Monday morning excitement. JUnit tests that pass in the IDE fail in ant and cruise servers running on all platforms.
java.lang.AssertionError:
Expected: a string containing “… text=Ç…”
got: “… text=Å…”
My immediate reaction was the encoding used by the JVM. Setting the “file.encoding” system property to UTF-8 did not help. Running the ant based [...]
August 26, 2009 - 1:06 pm
And in addition to that:
Percentage doesn’t really reflect the amount of untested/uncovered code. What are 50% in a file of 10 lines compared to 50% in a file with 1000 lines?
August 26, 2009 - 6:29 pm
If you want code coverage you can always use the eclemma osgi hook, but I agree use it only for what is not already tested not as a percentage.
http://www.eclemma.org/devdoc/headless.html
its very easy to add when creating headless builds, and the output can be imported in the eclipse IDE
September 1, 2009 - 12:16 pm
Code coverage does not reflect the complexity of code. A “get my member variable” as “return m_Value;” will never break… We are using Crap4J to combine unit test coverage with code complexity. You can get an easy overview here: http://www.crap4j.org
December 30, 2009 - 1:17 pm
@Mikkel
emma is maintained anymore ? I didn’t see any release or bugfixes after 2005. I was planning to shift to cobertura ?