February 2009 - Posts

Request for help with PhD Research
Thu, Feb 26 2009 15:34

Whilst at SC2009 today a request was made by Emad Ghoshen for attendees, and any other developers they knew, to assist him in his PhD research into maintainability of web applications.

He asked if people could download some Java/JSP code and answer a few questions on it, don't worry if this is not your usual languages this is one of the questions he is researching.

All the details can be found at http://www.sueblack.co.uk/clarosexp.html,

Intent is the key - thoughts on the way home form Software Craftsmanship 2009
Thu, Feb 26 2009 15:33

Today has been interesting, I have been to conferences where you sit and listen, such as DDD, TechEd etc. I have been to conferences where everyone is encouraged to talk open spaces style such as Alt.Net, but today has fallen between the two styles.

The Software Craftsmanship 2009 conference has been in more of a workshop style; most sessions have started with a short presentation to set the scene then the attendees split to forms small groups to do some exercise or chat, reporting back later in the session. A sort of lead open spaces feel if you want.

As usual with events you need to let what you heard sink in, but I think it will be useful. Not so much in the 'I must do X to fix project Y' but in the general approach to development issues. This was a conference on craftsmanship, best practice in general not magic bullets. A good example was in the session on responsibility driven design with mock objects, where a good deal of time was spent discussing the important of variable/object names in the design. From this session you should not take away that 'View' is a bad name and 'Display' is a good one; but that the choice of the name is important to how you will view the intent of the test and the code you are writing.

I suppose this was the theme for the day, in development intent is key, why you do something is more critical than how. It is only through clear understanding of the intent of the business users that a developer can hope to design the best system. So often what the client asks for is based on what they think can be done and unless this requirement is challenged to get at the underlying intend the best solution (whatever best means to the project) will be missed. The same holds true with writing tests, it is vital that the test conveys the intent of what is being tested, else there is little hope for any future maintenance work when all the original staff have moved on. This means to me that the most important part of the user story is the 'so that they can' clause at the end, it is so often the window onto the truth of the real story intent behind the story.

So an excellent day all round, thanks to Jason Gorman and everyone else who helped to organise the event, I look forward to next years, and so should you if you are interested in your craft....

Do you need work item hierarchy in TFS?
Wed, Feb 25 2009 10:14

Is so have a look at Notion Tools from Team System. This set of tools provides

  • A timesheet based on works items that you access inside Visual Studio
  • A work organizer  to manage work items and documents allowing creation of hierarchies
  • A work planner to help schedule resources for future iterations.

Well worth a look as a means to extend the reach of TFS into your Agile projects.

by But it works on my PC!
Filed under:
SLExtensions HTMLEditor
Wed, Feb 25 2009 8:32

I have been looking at porting a old content editor I wrote from WinForm to SilverLight and hit the problem there was no HTML editor control available in the standard Silverlight 2 control set. Roll in the excellent SLExtensions controls on CodePlex, to save the day.....

Now I did hit one problem with the HTMLEditor, that was addressed very quickly in for support forums. The point to watch out for is that for the HTMLEditor control to work the Silverlight object must be loaded into the web page with the setting to be windowless

<object id="appId"  data="data:application/x-silverlight," type="application/x-silverlight-2" width="100%" height="100%" > 
    <!-- all the other parameters -->
    <param value="true" name="windowless"/>
</object>

If you just add the object with default settings to a new web page, or let Visual Studio generate a dynamic test page then this is not set. You end up rendering the editor but cannot enter text.

Hope this saves you some time.

Alt.Net UK 'In the North' Registration is now open
Tue, Feb 24 2009 6:29

You can now register at http://www.altdotnetuknorth.info/

New URL for Agile Yorkshire (nee XPClub)
Mon, Feb 23 2009 15:28

agileyorkshire.org is the new home for the Agile Yorkshire user group. If you follow the link you will see that next months subject is Test Doubles: An Introduction To Unit Test Patterns. Unfortunately I won't able able to make this session as I will be out of the country, but sounds interesting.

Excellent selection of speakers at the May Progressive .NET Tutorials
Mon, Feb 23 2009 15:05

You may have seen on a few blogs that Skills Matter are organising the Progressive .NET Tutorials, a 3 day event in May. I have to say that the selection of speakers is excellent including Hammett, Ayende Rahien, David Laribee, Gojko Adzic, Ian Cooper, Mike Hadlow, Scott Belware and Sebastien Lambla; on subjects such as NHibernate, Castle, Monorail, Agile Testing, Web Testing, DSL's in C#, OpenRasta, Windsor WCF, MEF (Microsoft's Managed Extensions Framework) and more...

For the full programme and description see http://skillsmatter.com/event/open-source-dot-net/progressive-dot-net-exchange. There is a massive discount available to blog readers for this May .NET workshops. If you were thinking of signing up, quote SM1368-622459-33L in the promo code field which allows you to book the workshops for £350 (normal ticket price is £1000).

by But it works on my PC!
Filed under:
Update on Alt.Net 'In the North' Conference
Fri, Feb 20 2009 3:06

There is a bit more information on the the Alt.Net conference now at http://www.altdotnetuknorth.info/

Registration will open next week at noon on Tuesday the 24th February.

If Alt.Net is not to your taste.....
Wed, Feb 18 2009 9:58

On the same day as the Alt.Net event I am organising there is a community event at TVP 'WebDD'09 - With all the latest stuff from MIX 09'.

We are spoilt, there is so much choice in the community events at this time of year

Announcing the Alt.Net.UK 'in the North' Conference
Wed, Feb 18 2009 4:50

I am please to be able to announce that there will be an Alt.net Open Space Conference in Bradford on the 17/18th April this year. I had mentioned my intension of organising such an event at the last London conference, but it has taken a bit longer than expected to get sorted due to problems with getting the venue.

The event will be hosted by Black Marble at their office in Bradford, West Yorkshire, and there will be space for 50 attendees. The format will be the same as previous UK Alt.net conferences.

  • A planning session on Friday the 17th April from 7pm to 8:30pm, followed by a trip to a bar to socialise
  • The open spaces sessions from 9am to 4:30pm on Saturday 18th April.

As well as providing a venue for the event, Black Marble has kindly agreed to also sponsor lunch on the Saturday.

Other offers of sponsorship will be greatly appreciated

I will get some more detail posted on the web such as registrations, local hotels etc. ASAP.  Check this blog for details

What is the conference format?
The conference will be based on the open spaces format.

An Open Space conference's agenda is decided upon by the conference participants during the opening of the event. Whoever shows up is the right group. Whatever happens is the only thing that could have. Whenever it starts is the right time. When it's over, it's over. 

What is Alt.Net?
Various blog posts have defined Alt.Net. Term originally coined by David Laribee on his blog.

Who are the organisers?
Richard Fennell, Iain Angus  and Nick McKenna

Black Marble is providing sponsorship and logistic support. 

Buzzword bingo in the cloud
Fri, Feb 13 2009 7:26

At todays Azure event I heard a new word for my occasional buzz word posts.

Marketechture - an architecture designed by marketing for use in Powerpoint

SQLBits IV registration is open
Wed, Feb 11 2009 8:33

You can now register for SQLBits IV in Manchester on the 28th March, hurry if you want to attend as these free conferences do tend to full up quick

My session has been selected for SQLBits IV
Sun, Feb 8 2009 14:44

Thanks to everyone who voted for my session 'Making the SQL developer one of the family with Visual Studio Team System', it was successful in the selection process and so will be on the agenda at SQLBits IV on 28th March 2009 in Manchester

Hope to see you there.

Missing .NET framework installing a VSTO application
Sat, Feb 7 2009 12:36

I have been getting the error "The required version of the .NET Framework is not installed on this computer." (event id 4096 in Event log) when trying to install a VSTO application from both a ClickOnce deployment and a local copy. This is interesting as the .NET framework is installed (on my 64bit Windows 7 PC) and the VSTO application was developed on the self same machine (and works in Visual Studio 2008).

The fix, it turned out, was to uninstall Microsoft Visual Studio Tools for the Microsoft Office system (version 3.0 Runtime) (x86) and then reinstall it, once this was done the install worked fine.

Free events in the coming week
Sat, Feb 7 2009 5:51

I know of two free events next week in Yorkshire next week for those interested :

On Wednesday the 11th is the regular meeting of the Agile Yorkshire user group, where we will be enjoying a presentation on Test Driven Development by user group regulars Adam and Neil from Masternaut ThreeX. This will start at 7pm as normal, but some of us are planning to arrive about 6:30 to discuss some administrative issue of the user group. So if you are interested just turn up at the Victoria Hotel.

On Friday the 13th we at Black Marble are hosting a Microsoft Azure Technical briefing where Dave Gristwood and other member of the DPE team will be covering how this new technology can be used in your ongoing IT strategy. For this event you need to book in advance, so check the DPE blog for details

Which way to fake an item in Typemock
Thu, Feb 5 2009 15:22

I raised a question on the Typemock forum concerning a problem I was having mocking Sharepoint SPFarm objects. It was all down to which way to fake items using the various techniques in Isolator. It was interesting enough, I thought, to repeat here as a blog post.

I had written some tests for a method that got a list of SiteCollections that a user had rights to access. The key point being the need to access the static property SPFarm.Local to get a list of Sharepoint services to iterate across. If I ran each test by itself it worked; but if run as a batch in TestDriven.Net or MSTest the first passed and the rest failed.

The problem was down to how I was creating the fake SPfarm, I was using:

SPFarm fakeFarm = Isolate.Fake.Instance<SPFarm>(Members.ReturnRecursiveFakes);
Isolate.Swap.NextInstance<SPFarm>().With(fakeFarm);

when I should have used

SPFarm fakeFarm = Isolate.Fake.Instance<SPFarm>(Members.ReturnRecursiveFakes);
Isolate.WhenCalled(() => SPFarm.Local).WillReturn(fakeFarm);

Ok, I used the wrong call, but wait a minute, each of my tests were marked with the [Isolated] attribute. My understanding was this meant the Typemock system was reset between each test, and as I only call SPFarm.Local once per test were these two forms not equivalent?

This is the answer from Doron at Typemock, hope it clear up any confusion of the type I was suffering from.....

You are right in that the Isolate attribute resets fake behavior between each and every test. However, SwapNextInstance<T> is triggered if and only if a constructor for T has been called. It is not equivalent to WhenCalled() but rather complementing.
Generally speaking, you set behaviors on your fake object (or static methods) using WhenCalled() and then you can choose how to inject that fake behaviour to the code under test:
- If the code under test receives a reference to the fake behavior, you just pass it in.
- If the code under tests receives it from a third party, you fake that third party to return the fake object you set up.
- If the code under test uses 'new' to instantiate the dependent behavior, use SwapNextInstance to replace the next 'new' with the faked object

Developer Day Scotland Voting Opens
Wed, Feb 4 2009 14:46

The voting process has opened for Developer Day Scotland being held on the 2nd of May. I would like to draw you attention to my proposed session on testing for Sharepoint developers where I will show what can be done with Typemock and good use of design patterns to allow the building of complex tests that can be run of build servers that do not require Sharepoint to be installed.

But even if you don't fancy this session please still vote, and when it opens sign up to attend DDS. In my opinion DDS was the best of the DDD events I went to last year. A great venue and atmosphere.

GetReady2-smallCAOFIQNI

by But it works on my PC!
Filed under: ,