<feed xmlns="http://www.w3.org/2005/Atom">
  <div xmlns="http://www.w3.org/1999/xhtml" class="info">
         This is an Atom formatted XML site feed.
         It is intended to be viewed in a Newsreader or syndicated to another site.
         Please visit <a href="http://www.atomenabled.org/">atomenabled.org</a> for more info.
  </div>
  <title>Blogging Pubbitch</title>
  <link href="http://www.pubbitch.org/blog/index.atom" rel="self"/>
  <link href="http://www.pubbitch.org/blog/index.html" rel="alternate" type="text/html"/>
  <id>http://www.pubbitch.org/blog/tech.atom</id>
  <updated>2008-07-25T21:07:41+00:00</updated>
  <author>
    <name>Simon Stewart</name>
  </author>
  <entry>
    <id>tag:pubbitch.org,2008:entry,121343041050253</id>
    <title>Gears on Firefox 3</title>
    <link href="http://www.pubbitch.org/blog/2008/06/14/gears_on_firefox_3" rel="alternate"/>
    <updated>2008-06-14T08:00:10Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>I must be late to the party, but <a href="http://gears.googlecode.com/">Gears</a> finally works on Firefox 3, which is a Good Thing considering that <a href="http://www.mozilla.com/en-US/firefox/3.0rc3/releasenotes/">RC3</a> has just been released. Yay! On the downside, <a href="http://reader.google.com">Google Reader</a> isn't showing up properly when I access it offline. Oh well, I'm sure that it'll be fixed soon.
</p><p>
On a related note, I've had the opportunity to delve into the Gears codebase. There's some pretty cool stuff in there, and if it wasn't Open Source it wouldn't have been so easy to use it as a learning tool. It's a pretty hefty amount of code, which makes getting to grips with it a slightly intimidating experience, but it's organised well and once you've started it starts to make more sense. 
</p><p>
I find myself wondering how easy it is to attract new developers to the project: I know that the number of languages used in WebDriver puts some potential contributers off, and we've got far less &quot;mass&quot; to deal with. I'm working on the theory that the modularisation of both projects helps make getting started easier, and once people are involved it becomes less daunting to tackle the areas that seemed too hard to even look at.</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,121298509322055</id>
    <title>New WebDriver Binaries Available</title>
    <link href="http://www.pubbitch.org/blog/2008/06/09/new_webdriver_binaries_available" rel="alternate"/>
    <updated>2008-06-09T04:18:13Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>I'd like to announce that we've made some new binaries of <a href="http://webdriver.googlecode.com/">WebDriver</a> available. What does this cornucopia of goodness bring you?
</p><p>
<ul>
  <li>&quot;Zero install&quot;. Just drop the JARs into your project to get going. No installing DLLs or setting up Firefox profiles is needed.
  <li>DOM navigation: use a WebElement as the start of another search for elements</li>
  <li>Better IE support</li>
  <li>Faster XPath in IE</li>
  <li>Easy custom profile support in Firefox</li>
</ul>
</p><p>
That last feature may need a little explanation, so perhaps an example of how to create a new Firefox profile on the fly would help:
</p><p>
<pre>
FirefoxProfile profile = new FirefoxProfile();
profile.addExtension(new File("/path/to/an.xpi"));
WebDriver driver = new FirefoxDriver(profile);
</pre>
</p><p>
I use this to install <a href="http://www.getfirebug.com/">Firebug</a> because it's sometimes useful to have it around when debugging. You can probably imagine a host of different extensions you'd like to use too.
</p><p>
The binaries are available from the <a href="http://code.google.com/p/webdriver/downloads/list">Google Code site</a>. If you'd like help getting to grips with them, the <a href="http://code.google.com/p/webdriver/wiki/GettingStarted">wiki</a> may help and there's also a <a href="http://groups.google.com/group/webdriver">mailing list</a> and group available: we're a friendly bunch, and new users are welcomed!</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,120913119587091</id>
    <title>Consuming Buckets of Phalli</title>
    <link href="http://www.pubbitch.org/blog/2008/04/25/consuming_buckets_of_phalli" rel="alternate"/>
    <updated>2008-04-25T13:46:35Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p><a href="http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=477454">This</a> is the reason why you want a code review of anything that goes into an Open Source project. Leif's comment towards the end seems well balanced and polite.</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,120894659753247</id>
    <title>An Open Letter in Favour Of Using Sets</title>
    <link href="http://www.pubbitch.org/blog/2008/04/23/an_open_letter_in_favour_of_using_sets" rel="alternate"/>
    <updated>2008-04-23T11:57:12Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>To whom it may concern,
</p><p>
I note with consternation that there appears to be widespread abuse of <a href="http://java.sun.com/javase/6/docs/api/java/util/List.html">java.util.List</a> and <a href="http://java.sun.com/javase/6/docs/api/java/util/Set.html">java.util.Set</a>, and I believe it best to set the record straight forthwith. 
</p><p>
The most important issue to bear in mind when choosing between the two aggrieved parties is whether duplicates are important. If they are, then I humbly concur that "List" is the correct choice. If, however, it is deemed that duplicates are not desirable, then "Set" would be a more apt choice.
</p><p>
Consider also whether the ordering of elements within the collection matters to you, and in particular whether insertion order is maintained. Lists typically maintain their elements in insertion order. Sets tend toward ordering the elements by their natural ordering, though as with the case of that <a href="http://www.urbandictionary.com/define.php?term=red+headed+stepchild">red-headed step-child</a>, the <a href="http://java.sun.com/javase/6/docs/api/java/util/LinkedHashSet.html">LinkedHashSet</a>, this need not be the case.
</p><p>
Bearing these points in mind, it is with the greatest hope that I await the improvement of java.util.Set and java.util.List's situation.
</p><p>
Your humble servant,
</p><p>
Simon</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,12073104899188</id>
    <title>XML in Feeds</title>
    <link href="http://www.pubbitch.org/blog/2008/04/04/xml_in_feeds" rel="alternate"/>
    <updated>2008-04-04T12:01:29Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>I've had a couple of reports that my atom feed was broken. It was because of XML parsers doing what the spec says and choking on poorly formed XML (unbalanced tags in this case, where XML states that "a" and "A" are different)
</p><p>
I've now run the thing through the quite wonderful <a href="http://feedvalidator.org">feed validator</a>, so here's hoping that everything continues to work!</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,120474919501617</id>
    <title>The Single Best Bit of Code I've Seen All Day</title>
    <link href="http://www.pubbitch.org/blog/2008/03/05/the_single_best_bit_of_code_ive_seen_all_day" rel="alternate"/>
    <updated>2008-03-05T20:33:15Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>This is, quite possibly, the best piece of code I've seen all day: <a href="http://mxr.mozilla.org/mozilla/source/netwerk/test/httpserver/">httpd.js</a>. This is going to save me a huge chunk of effort as I work on updating the Firefox driver to be easier to use remotely.</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,120443101701681</id>
    <title>WebDriver and Selenium 2.0</title>
    <link href="http://www.pubbitch.org/blog/2008/03/02/webdriver_and_selenium_20" rel="alternate"/>
    <updated>2008-03-02T04:10:17Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>The first public commit to the <a href="http://webdriver.googlecode.com/">WebDriver</a> repository was on 31st December, 2006. Some 280 revisions and 421 days later, it looks like its days are numbered. It's achieved far more than I thought it would; there's support for <a href="http://code.google.com/p/webdriver/wiki/FirefoxDriver">Firefox</a>, various versions of <a href="http://code.google.com/p/webdriver/wiki/InternetExplorerDriver">IE</a> and some basic support for <a href="http://code.google.com/p/webdriver/wiki/SafariDriver">Safari</a>. I've written proof-of-concept bindings of the IE driver in C#, <a href="http://code.google.com/p/webdriver/source/browse/branches/first_python/jobbie/experiment.py">Python</a> and Ruby, and I'm told that people have bindings for the Firefox driver that sink support for it into the Ruby on Rails testing grammar. Better yet, people are <a href="http://it-republik.de/jaxenter/jax/sessions.php?tid=687#session-10">presenting</a> about it at conferences and the community behind it is starting to grow.
</p><p>
Why, if it's all going so well, are its days numbered? The answer is that &quot;WebDriver&quot; won't be around for too much longer because it's going to become part of the <strong>Selenium 2.0</strong> effort. 
</p><p>
The original version of this post posed the questions &quot;why do that?&quot; and &quot;what does it mean?&quot;, but you know what? I'm going to answer those in a different post. For now, I think the most important thing to remember is that this is going to make Selenium even better. It's going to be great!
</p><p>
The official announcement was at the recent <a href="http://google-opensource.blogspot.com/2008/02/selenium-users-event-coming-up.html">Selenium User Open Evening</a>. I have to say &quot;thank you&quot; to the <a href="http://www.flickr.com/photos/42666522@N00/2298621006/">Selenium development team</a> for even thinking about this, and to all the people who have had a hand in making WebDriver as complete as it is. More so, I should thank the early adopters for their feedback and comments, both on the <a href="http://webdriver.googlecode.com/">project page</a> and the <a href="http://groups.google.com/group/webdriver">mailing list</a>. Thank you!</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,120362032664521</id>
    <title>Initial Notes On Upgrading WebDriver to Work With Firefox 3</title>
    <link href="http://www.pubbitch.org/blog/2008/02/21/initial_notes_on_upgrading_webdriver_to_work_with_firefox_3" rel="alternate"/>
    <updated>2008-02-21T18:58:46Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p><a href="http://developer.mozilla.org/devnews/index.php/2008/02/12/firefox-3-beta-3-now-available-for-download/">Firefox 3</a> is coming, and it's about time I started looking at updating the <a href="http://webdriver.googlecode.com/">WebDriver</a> extension so that it works with it. 
</p><p>
It's pleasing to see that the first page that shows up when you start beta 3 is a "help sheet", containing links to a bunch of useful information. There's also a helpful page on the Mozilla website containing information for <a href="http://developer.mozilla.org/en/docs/Firefox_3_for_developers#For_XUL_and_extension_developers">XUL and extension developers</a>. Notable for WebDriver is the fact that <a href="http://developer.mozilla.org/en/docs/FUEL">FUEL</a> appears to be far more advanced than it was, and that there's native support for <a href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIJSON.html">encoding and decoding JSON strings</a>, which should give a small speed boost. Now, if only there was an embedded HTTP server!
</p><p>
I've yet to see if Firefox 3 is a <a href="http://developer.mozilla.org/en/docs/XULRunner">XULRunner</a> app, but if it is then there's a new avenue for automation that is opened up: <a href="http://developer.mozilla.org/en/docs/JavaXPCOM">JavaXPCOM</a>. 
</p><p>
From my initial explorations, this looks like it's going to be relatively painless. I'll keep you posted.</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,120335775243191</id>
    <title>I'll Be At the Selenium Users Open Evening</title>
    <link href="http://www.pubbitch.org/blog/2008/02/18/ill_be_at_the_selenium_users_open_evening" rel="alternate"/>
    <updated>2008-02-20T00:08:22Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>On Monday, 25th February, I'll be at the Selenium Users Open Evening. I'll be doing a Lightning Talk on the relationship between <a href="http://webdriver.googlecode.com/">WebDriver</a> and <a href="http://www.openqa.org/selenium-rc">Selenium</a>, which will be a (very) swift overview of what WebDriver is before delving into the meat of the matter. There probably won't be <a href="http://www.youtube.com/watch?v=Vlz-WmcrBL8">a duel</a> this time!
</p><p>
There will Selenium developers from as far apart as Tokyo, London and the US attending, so it's a great opportunity to meet up with these guys. Better yet, the event is open to the public, so it's the perfect chance to meet Selenium users and talk about next generation web testing. It's being run at the main Google campus in Mountain View from about 6pm. I'm sure that someone, somewhere will post more comprehensive details and I'll link to these when they're posted, but I hope to see you there!
</p><p>
<strong>Update:</strong> Details are up <a href="http://selenium.openqa.org/meetup.jsp">here</a> on the OpenQA site now.</p>      </div>
    </content>
  </entry>
  <entry>
    <id>tag:pubbitch.org,2008:entry,120326703039916</id>
    <title>Moving Into the Cloud: Email update</title>
    <link href="http://www.pubbitch.org/blog/2008/02/17/moving_into_the_cloud_email_update" rel="alternate"/>
    <updated>2008-04-04T11:57:14Z</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
<p>Time for an update about my experiment about moving into the cloud. The original plan involved importing my email into Mail.app and copying from there into gmail. It turns out that this is an appalling idea for two reasons. 
</p><p>
The first is that it'll take until approximately the heat death of the universe to copy my emails up this way. When the connection drops, which it does from time to time, Mail.app displays a friendly error message and stops. This sub-optimal behaviour means emails must be ferried up to the server in batches of about 200-400. Given that there are several tens of thousands of emails, this is a tedious process at best.
</p><p>
Secondly, gmail gets the wrong dates attached to the messages; using the date on which the message was uploaded rather than the date in the email itself for the "Date" column. Without sniffing network traffic, I suspect that what's happening is that either Mail.app isn't setting the date right in the <a href="http://www.apps.ietf.org/rfc/rfc2060.html#sec-6.3.11">APPEND</a> command, or it's omitting it and gmail is guessing the date wrong, possibly because it's not parsing the incoming message. Or it might be both. Who knows? Either way, the wrong date is being displayed.
</p><p>
I think what we need here is a decent dose of automation. What's the point of being a geek if I don't take advantage of the awesome power of the computer? If the emails were appearing in gmail with the correct date, I'd suck up the pain of the one time import from mbox into Mail.app and use the wonder of Applescript to automate the upload, but since it's not and the <a href="http://docs.codehaus.org/display/JRUBY/2008/02/16/JRuby+1.1RC2+Released">JRuby 1.1RC2</a> has just been released, now's as good a time as any to see whether I put together a little ruby script to do the hard work. 
</p><p>
Initial poking around suggests that this won't be too hard. There's a nice <a href="http://www.ruby-doc.org/stdlib/libdoc/net/imap/rdoc/index.html">Net::IMAP</a> module in the core Ruby distribution, and a tinker with <a href="http://poignantguide.net/ruby/expansion-pak-1.html">irb</a> quickly shows that it's possible to connect successfully and get some basic information out of gmail. Now, here's hoping that my mbox file and Maildir files are in <a href="http://www.apps.ietf.org/rfc/rfc822.html">RFC 822</a> format (or that gmail isn't too fussy about its inputs) I wonder if there's an implementation of the <a href="http://www.apps.ietf.org/rfc/rfc3502.html">IMAP Multiappend extension</a>?
</p><p>
If this doesn't work, then I may have to follow the advice of my friends and do the decent thing: set up an IMAP server somewhere and just do a straight copy. That plan reeks of "sounds easy, but isn't" to me, but that's because I'm a wimp when it comes to things like this. I'd use Google's email importer if it supported standard gmail accounts.
</p><p>
Right, time to throw some scripts together. How hard can this be?
</p><p>
<strong>Update:</strong> Ah! The wonders of Google. With the aid of <a href="http://blog.tquadrado.com/?p=166">this script</a>, it looks like this won't be too bad. I've done a quick experiment with Maildir and mbox format folders and it looks like we're good to go. Wish me luck.</p>      </div>
    </content>
  </entry>
</feed>
 
