Friday, June 05, 2009
Have you heard of Project Natal? If not then you’re definitely sleeping…
Fortunately I hereby provide you a real nice video that should hook you up :)
Until next time ;)
Friday, April 24, 2009
Many people still think like this. Others think they know what MVC is, but are all wrong. Another type of developers still think that Web Forms is the way to go and MVC generates all bunch of crappy code.
To all of them I say this: Go Learn MVC Now!
…or go read Rob Conery’s post. He wrote a all lot better the reasons why you should learn MVC than I could ever write.
Until next time ;)
You’re probably wondering why I’m jealous of the Norwegians. As you know, I live in Portugal, that beautiful place bathed by the Atlantic ocean. And now you thinking: “He lost it completely. How could he be jealous of the Norwegians? They have snow and cold when he has sun and warm temperatures. He has lovely beaches when they have nice rocks.” Well, all of that is true. But I’m still jealous and the reason is this.
The Norwegians are so luck. They have the opportunity of watching speakers like Scott Hanselman, Phil Haack, Michael Feathers, Robert C. Martin (aka Uncle Bob), Roy Osherove, Juval Lowy, Ted Neward, Michele Leroux Bustamante, Ayende Rahien, Jeremy D. Miller, Ian Griffiths, Jimmy Nilsson, Scott Bellware and Glenn Block, just to name a few. And all of them are going to be there this year. All together. Oh…I’m so jealous!!!
At some point, in the NDC site, you can find the following:
“The idea behind Norwegian Developers Conference is that it should be able to measure up against any conference in the world. All the speakers are experienced and right at the top of their respective trees.”
I don’t remember in Portugal having this quality in our developer conferences. Until when I have to wait to someone come up with a conference with this quality in Portugal? Until when I have to wait to watch Scott Hanselman or Jeremy D. Miller without having to exit my country?
In Portugal, I estimate that exists, more or less, 10.000 developers. There’s enough audience to support a conference of this quality. I hope that this post enlights someone (aka business-person) to start a similar developer conference able to rival with the best in the world.
Until next time ;)
Wednesday, April 22, 2009
Today, I’ve watched the presentation that Scott Hanselman gave in Devscovery last monday. (if you also want to watch it, check Scott’s post)
His keynote got me thinking, whereas the reason for this post. I’m just going to write about my own experiences and I assume that who reads this later may or may not agree with me.
I’m not social. Period!
You may think that as developers our work needs a very small percentage of social interaction. Basically, meetings. Well, but if we want to succeed as developers and climb the ladder in software engineering you’ll need social interaction. I’m really up for information/knowledge sharing. We, the geeks, know the tools that better help us doing that sort of thing.
Where am I
- Blog: This blog has the purpose to share my ideas with others (and getting their reaction, which until now result in just one person) but mainly I’m using it in order to google myself later :) and you can find great developer/blogger out there that have valuable information. I do think that reading blogs is far more important than writing one. There are already great information on how build apps using best practices, a specific technology, how to test our code and so on.
- Linkedin: In the past it was usual to exchange business cards. I remember my father having an agenda with all his connection’s business cards. But now, I use Linkedin simply because the people on my network is constantly updating their profile and anyone who wants can check what I’m doing or what I’ve done. Since I created my profile I was contacted more often, for job interviews.
- Twitter: Where you’ll find me more often. I really like the way I’m getting information from the people I follow. The Twitter usage is suppose for you to write what you’re doing. But I’m using it mostly to share articles and posts that I find interesting. And that engaged some very interesting discussions.
- Stackoverflow: I blame myself for forget to mention that lately you can also find me at Stack Overflow. It’s an incredibly web app that allows a community information exchange. The site is like QA with wiki. Very cool. Way better than this one. [UPDATE]
It’s all about sharing information
I think that is also important some sort of gathering where we all discuss and exchange ideas in software engineering. See one of my latest posts:
…put people talking and sharing experiences with each other.
The bottom line is: developer meeting the social == exchanging information
Until next time ;)
Wednesday, March 04, 2009
In case you didn't notice, ASP.NET MVC RC2 is out. Following that release, I've decided to create a new ASP.NET MVC project, but using xUnit instead of MSTest for the test framework. I also want this change to have no impact in the way I develop, which means that I want the unit tests to run inside Visual Studio 2008.
Why xUnit?
Here's why.
Introducing Gallio
From Gallio homepage:
The Gallio Automation Platform is an open, extensible, and neutral system for .NET that provides a common object model, runtime services and tools (such as test runners) that may be leveraged by any number of test frameworks.
The Gallio platform seeks to facilitate the creation of a rich ecosystem of interoperable testing tools produced by and for the community at large so as to address a far wider range of testing needs than any previous independent testing framework has done before. Unit tests, integration tests, performance tests, and even semi-automated test harnesses should all be able to leverage common facilities where appropriate. Moreover, they should present consistent interfaces to the world so that they can easily be integrated into the systems and processes of the enterprise.
At present Gallio can run tests from MbUnit versions 2 and 3, MSTest, NBehave, NUnit, xUnit.Net, and csUnit. Gallio provides tool support and integration with CCNet, MSBuild, NAnt, NCover, Pex, Powershell, Resharper, TestDriven.Net, TypeMock, and Visual Studio Team System.
Combining all together
DISCLAIMER: The following steps are provided "as is" without any warranty or support. Use this under your own responsibility. Also, this only works in Visual Studio 2008 Team System and I'm assuming that you already have the ASP.NET MVC RC2 installed (but I assume that this also works with RC1 but I haven't test it).
1. Download xUnit (xunit-1.1.zip) and Gallio latest releases.
2. Unzip the xUnit file and run the xunit.installer.exe. In the ASP.NET MVC section click on the Enable button (case it's enabled which in this case you'll need to do nothing) and you'll get the green result, like in the picture below.
3. Execute the downloaded GallioBundle-3.0.5.546-Setup-x86.msi installer and follow the instructions.
4. Create a new ASP.NET MVC project. When the below screen appears you're now able to choose the xUnit as the test framework. Click OK.
5. Now the tricky part. Unload the test project (right-click on the project and choose the Unload project option).
6. Right-click on the unloaded project and choose Edit...csproj and you'll get something like this:
7. Right below the
element paste this.
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
8. Save and reload the project.
9. Build the solution. Probably you'll get the errors below (if not go to step 10). This happens because the xUnit project templates are built for the ASP.NET MVC RC1 and we're using the ASP.NET MVC RC2. Simply add references in the test project to the assembly System.Web.Routing and System.Web.Abstractions. See the
release notes in case you're interested knowing what changed. Basically, this assemblies are no longer distributed with the MVC installer because are already shipped with .NET Framework 3.5 SP1.
10. Build again the solution and hopefully all goes OK.
12. Select all and run. You're now running the tests successfully inside the
Visual Studio 2008 with
Gallio (Check the icon between the checkbox and the result column).
The two last tests are failing, once again, because are built for the RC1. I'll leave the resolution to you :)
Success! Hope this helps someone.
Until next time ;)
Tuesday, March 03, 2009
Last weekend it was held in Seattle the ALT.NET conference. One of the things that grabbed my attention was that they practiced the Open Space Technology. That's an interesting approach on sharing our thoughts with the all the ones attending the conference. Although, at least for me, the real advantage of the ALT.NET conferences (and also the ALT.NET user groups) is that put people talking and sharing experiences with each other.
For the past weeks Bruno and I have been talking about patterns, methodologies, open source apps and alternative tools. I think that's very into the ALT.NET spirit. Unfortunately, our thoughts are being kept just to us. No one is taking advantage of our conclusions.
My vision is: a software discussion user group in Portugal (or one in Lisbon and another in Porto). I'm releasing this thought as my own. I haven't shared it with anyone. But I would like to know if someone else thinks like me and advocates this idea. I know that exists this group that have been engaging a lot of discussion in the subject of software. But I would like to have in Portugal a freely available discussion on software open to everyone. Senior developers mixed with junior and newbies. A real exchange.
Please send me an email with your suggestions\ideas (rodrigo [one dot] guerreiro [a] agilior [another dot] pt). I would like very much this idea to grow. That's my vision.
Friday, February 27, 2009
...here. Also I've updated my blog page with my recent tweets ( <-- left side).
If you're interested in the couple words that I mumble every once and a while, follow me :)
Wednesday, January 21, 2009
ONE YEAR. That's the time I had to wait to post a welcome to João Manso. Finally he started to post.
What I have to say about Manso (that's how we call him, or, as he prefers, "O Manso")?
I've worked with him in two distinct companies, including Agilior. Also he and Pedro were my classmates at ISEL.
It seems that I can't get rid off him. Just kidding!
Welcome Manso! :)
Tuesday, November 25, 2008
Typemock are offering their new product for unit testing SharePoint called Isolator For SharePoint, for a special introduction price. it is the only tool that allows you to unit test SharePoint without a SharePoint server. To learn more click here.
The first 50 bloggers who blog this text in their blog and tell us about it, will get a Full Isolator license, Free. for rules and info click here.
Friday, November 14, 2008
I know that I owe you, my faithful readers (which BTW my last reports tells me that in total are...hum...zero), a couple of posts since August. I promise that I'll try to keep you (I mean...no one) updated with my recent thoughts :)
Back to the real post...
Yesterday, in one of our clients, we found out a real nice and tricky bug. In the BizTalk solution we have a message schema that looks something like this:
It's typical to insert a validation rule in the email. So, the Email field should look something like this:

In case you're wondering, this is done by setting the Base Data Type property with xs:string, setting the Data Type property with "Email" (just write it out) and paste "\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*" (without the ") into the Pattern property.
Now let's generate an instance of this schema. One example that's complaint with this schema could be:
<ns0:Person xmlns:ns0="http://TestingEmailAddressFormat.Message">
<Name>John Doe</Name>
<Address>Lisbon street, 1</Address>
<Phone>555-5555</Phone>
<Email>johndoe@somewhere.com</Email>
</ns0:Person>
If you validate this XML against our schema you'll get the message "Validate Instance succeeded for schema Person.xsd...". Perfect!
But let's perform a small change in Email field:
<ns0:Person xmlns:ns0="http://TestingEmailAddressFormat.Message">
<Name>John Doe</Name>
<Address>Lisbon street, 1</Address>
<Phone>555-5555</Phone>
<Email>john_doe@somewhere.com</Email>
</ns0:Person>
Validating this won't get us that nice message of success. Instead we get something like "error BEC2004: The 'Email' element is invalid - The value 'john_doe@somewhere.com' is invalid according to its datatype 'http://TestingEmailAddressFormat.Message:Email' - The Pattern constraint failed". That's a little awkward, because we were sure that our regex expression was right.
After some googling, Bruno found the reason for this error. It seems that in the .NET framework the "\w" option is equivalent to [a-zA-Z_0-9]. As you can see, it includes the "_" (underscore). But in the XSD schemas, the "\w" option doesn't include the "_"(underscore).
Bottom line, we had to change our validation regex expression for the Email field to "[A-Za-z0-9_]+([-+.'][A-Za-z0-9_]+)*@[A-Za-z0-9_]+([-.][A-Za-z0-9_]+)*\.[A-Za-z0-9_]+([-.][A-Za-z0-9_]+)*" (without the ").
Until next time ;)