Wednesday 21 August 2013

North Brittany 2013

We booked a very last minute trip to north Brittany, to two camp sites just a few hours out of St Malo.

Saturday 27th July

Arrived just in time for ferry, fifteen minutes to spare, too close for comfort really. Great to have a cabin, had a meal and bought map etc. All slept well.

Sunday 28th July

Drove from St Malo to St Cast-le-Guildo. Drove straight to the Seymour's house, though it has been many years since I was last there.

Had a lovely walk along the beach, writing in the sand, collecting cuttle fish and Flora found two euros.

We split up and I ended up buying a coffee whilst Ellie used a loo, and spilt the whole cup in my lap, not best pleased.

We drove on to Camping le Cap Horn, where we were met with enthusiasm and great cheerfulness, which lasted the whole stay.

Our mobilhome had a covered porch with a great view over the bay. It was new this season, very clean and completely plastique!

Monday 29th July

We visited the E Leclerc at Paimpol for essentials. I spotted some cast iron crocottes, which we bought later. Bought Flora a digital watch.

Ruth knew she wanted to go to the Isle de Bréhat, so we went for a quick trip. Ellie bought the first of two thermometers. I caught eight fish from one tiny rock pool.

Tuesday 30th July

We went to an outdoor, tidal swimming pool.

Wednesday 31st July

On the way to a beach we stopped at a café

When we got to the beach

Flora and I launched the barge and coracle.

Thursday 1st August

Hung around.

Friday 2nd August

Ruth and Ellie walked to Abbaye de Beauport, Flora and I drove, via the Intermarche, where we bought some dolls house carpet.

The Abbaye is the start (km 0) of the pilgrimage to Santiago de Compostela.

Saturday 3rd August

We went for a boat trip around the Île de Beréhat, ending on the Île. We rented bikes and cycled around the whole island. We ate at a café on the main square. What a lovely place.

Our first stop was a tide mill.

We cycled all over both islands, spotting some beautiful cattle.

Sunday 4th August

Monday 5th August

Once packed and wished on our way we stopped at the Free Sculpture of Kito.

Bought some Cidre de Paimpol from the Carrefour to take home.

Stopped and horrified ourselves, at a travelling circus.

Arrived at Le Vieux Moulin Camping, Erquy.

Tuesday 6th Augst

Wednesday 7th August

Thursday 8th August

Ruth and the girls cleared out, for swim, whilst I had a 'phone interview with BlinkBox Music.

Went to Les Médievales de Fort La Latte.

Walked down to the beach at LanRuen, high tide but still very nice, through lovely woods.

Friday 9th August

Heard that BlinkBox did want to see me face to face, good end to the holiday.

Went to Pleneuf Val Andreé and had lunch at Plein des Sens. Then popped into a pottery owned by the café owners's mum.

Went down to the great beach at LanRuen, down from the camp site. It was low tide, there were fantastic rocks, a shoal of whitebait stranded in a large rock pool. We swam in the water, which was warm and a little wavy. We were sad to leave to pack up the mobilhome.

Saturday 10th August

Left the campsite at 8.20, though we had aimed for eight. No problems with the journey, arrived with fifteen minutes to spare.

Wednesday 14 August 2013

Reimplementing Length Unit Converter in Java

Back in April I did a programming exercise in Python, which I really enjoyed and resulted in PyCLU and its Jenkins node, I was slightly sorry not to set up the Jenkins node earlier in the process, so the coverage graphs do not start at zero.

Today I received the same exercise with the option of implementing in Python or Java, so I have decided to reimplement in Java, rather than reuse my python implementation.

Setup

Following Project Initiation Recipe

Choose short name

JCLU

Choose stack

This will be a pure java command line application. It will be built using Maven on OpenJDK 7, with version compatibility set to 1.6, this was initially 1.4, but revised in the light of use of annotations within the testing code. It would be possible to use 1.4 in the artefact code and 1.6 within the testing code, should that become a requirement.

Create Repo

The only decision is public or private. It will be a git repo: here.

Choose CI

My Jenkins.

Setup dev machine

My dev machine has been set up according to this Ubuntu Setup Recipe.

Checkout and create Maven project from archetype

Now we have a buildable artefact.

Setup on Jenkins

Nice and early on, so that we can see test coverage evolve. Here

Diversion to reimplement RDD in Java

In the Python implementation I added an iteration of Requirements Driven Development (RDD), a utility born out of the audit driven culture of the NHS.

Annotating each test with which requirements it addresses enables a tighter coupling between requirements and tests.

RDD fits into the evolution of Agile programming by analogy with one of the justifications for Test Driven Development:

Why are you writing code?
To make a test pass
How do you know when to stop?
When all tests pass
The motivation behind RDD similarly:
Why are you writing that test?
To satisfy requirement ref X
How do you know when to stop?
When all requirements are tested

Another motivation, and tie-in with general Agile principles, is that it ties documentation to the code: the requirements grow when new tests are written as unforeseen requirements surface.

In PyCLU I used annotations, this should be possible in java (I have not written a java annotation before).

The idea is that a dated Requirements Verification Document will be produced by running the tests, that the tests will fail if there is an unmet requirement and the document can be published by Jenkins: here.

Ready to start

Quite a lot of work just to get to the starting line!

Translated PyCLU into java, adding only one test, that the wrong number of arguments throws an exception and that the specified input produces the specified output. This showed the slight differences in the specification: JCLU does not need to output the full name of the unit, does not accept multiple units eg 1 yd 3 in and does not need to add units. Removed unspecified code. This achieves 100% code coverage.

Now to test the requirements!

Reintroduce equals() and hashCode() for testing.

Convert all relevant tests from PyCLU; add tests for unused but needed hashCode() and equals().

Add tests for units not in PyCLU.

Review and submit!