Goings on at Softwire, technical and otherwise

Archive for January, 2012


Web Development in 2012

It’s 2012 and we’ve seen a lot of new changes in web development in the last year or two. So here’s my quick overview of some of the highlights and some examples from the best of the web, along with lots of links!

READ MORE…


Unit testing NHibernate-based data access code using SQLite

Code that interacts with a database, either directly or through an Object-Relational Mapping (ORM) library like NHibernate, is often quite difficult to test. This blog post looks at unit testing data access code using FluentNHibernate mappings, but it should apply just as well to vanilla NHibernate and other ORMs.

NHibernate provides interfaces for everything, which you theoretically could use to provide mocks to your code under test, but mocking complex 3rd-party library classes like this is not necessarily a good idea: you’d need to know exactly how your code was using the NHibernate API in order to do so. It’s best to think of NHibernate as part of your standard library and provide a real NHibernate session to your code under test.

The problem with this is that a real NHibernate session needs a real database. If you want to test with the same DB as your production code, this means keeping a database server running for your test, getting data into it, working out how to cope with multiple tests using the same database, etc… the resulting test runs are going to be slow and a lot of work to maintain.

Enter SQLite. It’s a single-DLL relational database management system (RDBMS) that can create a database from scratch for each test (so no worrying about setting up fixtures for tests running in parallel), in a single file on disk or in memory (the latter of which is *fast*). Using SQLite for unit tests is nothing new, but there are a lot of configuration options to consider, and I thought it would be worth documenting the end result that we arrived at when doing this sort of testing on our previous project.

READ MORE…


How we run a software company: Monitoring employee progress

previous article in series

It is essential for any company to be aware of how each of their employees is getting on. Fail to spot and reward good work and you’ll have disaffected and un-incentivised employees. Fail to spot and correct poor work and you’ll fall some way short of 100% productivity.

It’s the nature of a Software house that employees will change teams often, with project lifetimes usually falling between one month and one year. This presents a challenge for monitoring progress, but also an opportunity.

At Softwire we recognise the importance of having some consistency in your management line, but we also consider it imperative that you’re looked after by someone who’s working with you on a day-to-day basis. That’s why everyone here has two managers: a Line Manager (LM) and a Task Manager (TM).

READ MORE…


Getting Objective, part 4: Please release me (let me go)

previous article in series

Recap

Last time, we enhanced our Hello World application so that it could interpret our feedback and take some appropriate action. I closed off by declaring it to be “very bad indeed“. This time, we’re going to find out why…

READ MORE…


Debugging Third-Party Applications – Part 2

previous article in series

This is a short series of posts about a problem I had with Microsoft Exchange’s Outlook Web Access (OWA): reading the Old New Thing blog through OWA suddenly stopped working with this error:

This link has been disabled for your security

In the first part I tracked down this error message to a static page UrlBlockedError.aspx in the OWA files on the Exchange server.

READ MORE…


Clandestine Maths Club: cosines and sequence alignment

previous article in series

So another week, and more exciting maths formulae posted up on the Softwire whiteboards.

READ MORE…


Debugging Third-Party Applications – Part 1

This is a short series of posts as a worked-example of how to debug into someone else’s code. It covers a problem I ran into with Microsoft Exchange’s Outlook Web Access (OWA), which Microsoft has since fixed, but the advice is intended to apply to many other situations.

READ MORE…


Getting Objective, part 3: How is the world, anyway?

previous article in series

Recap

In my first post, I wrote a very simple “hello world” application, that displayed an alert box like this:

Screenshot of the Hello World application popup

It’s lovely as far as it goes, but you were to install that application on your phone, you would no doubt become rapidly disillusioned with it – it may ask how you are, but ideally we’d want something to happen once we press a button. At the moment, all that would happen is that the popup would disappear, and you’d be looking at a white space. Admittedly, this is pretty much how some of the early torch applications worked, but I think we can all agree that we’re not (yet) putting Objective-C to its best use.

READ MORE…


Softwire interviewed by Warwick University

Warwick University wanted to know why we were at their careers fair, and how their students can get a job at Softwire. We were only too happy to oblige.

Here’s Harry Cummings, who studied at Warwick University:

READ MORE…