Posted in News on 01/20/2010 10:12 am by hilton.giesenow
One of the common techniques with Coding Katas is doing Test Driven Development (TDD), or at least having a good suite of Unit Tests for your code. Unit Testing with SharePoint is quite a bit more tricky though because of the dependence on the SharePoint libraries and runtime. This is where a product like TypeMock Isolator for SharePoint comes in to play. I recently interviewed Roy Osherove (see Unit Testing With Roy Osherove), noted Unit Testing expert for The MOSS Show and as a follow up, TypeMock are offering a discount on the SharePoint Isolator product. To take up the discount, listen to the intro to the most recent show (ISV Overview #1 – BA-Insight) for the discount code.
As I mentioned in the show intro, also on offer are a couple of free licenses for TypeMock Isolator – all you have to do is write in to the show with a great letter. The best letters will be read out in the show (you’ll be famous, too!) and will win a license.
Posted in News on 01/19/2010 04:47 pm by hilton.giesenow
One of the practices I’m trying to improve on in my teams is working with string literals. In Feature XML files, for instance, we can set the DisplayName of a Site Column to pull from a localized resource file instead of being hard-coded. See here for an introduction by Ton Stegeman. In addition to being able to localize the values, the resource file creates a strongly-typed “code behind”, if you like, which is a wrapper resource manager to allow you to access the values from code directly. This Kata is about practicing the pieces of this.
Here are the steps:
- Create a new Feature called “Testing Resources Feature”
- Add a Site Column called “My Test Column”
- Add a Resource file
- Create entries in the Resource File for these two strings
- Use the strings in the Feature and Site Columns xml files
- Modify the Site Column’s “Name” property to also use a Resource setting
- Create a new list definition in the Feature to use the new Site Column
- Add an item to the list in the Feature Receiver and use the strongly-typed Resource key to access the field
Posted in News on 01/04/2010 04:50 am by hilton.giesenow
A SharePoint Kata? What’s that? Well, it all goes back to Coding Katas – an idea based on martial arts where we try to regularly hone and improve our coding skills with specific exercises. For more information, and more links, see the About page on this site.
When it comes to SharePoint, the goal is to propose and discuss Katas to improve our skills in this domain. However, they’re not just for developers – administrators and even users can benefit from doing some regular activities. Here are some possible benefits:
- Improving, refining and honing existing skills, so we get better at what we do already
- Repeating Katas over time, so we don’t forget something we did and knew in the past
- Learning new SharePoint skills as we get to try a small (e.g. 30 minute) task focused on something we haven’t done before.
Some of the best Katas are those done in pairs! The goal of this site is to help us improve, share, discuss and learn together, so get involved by suggesting your own Katas, commenting on the ones here already, and helping to build some real SharePoint Ninjas!