Archive for September, 2009
Nice UX on The Book Depository’s Payment Page
Quite often, when buying books off Amazon, you can sometimes get them cheaper by going to a marketplace seller’s own website. That’s how I came across The Book Depository, where I have bought a few books recently.
One nice UX feature that I like on this site was the way in which they highlight where to find your credit card CVV/security number depending on which credit card you are using:
The image above shows the security number highlighted on the signature strip when you select Visa from the credit card type drop-down list. Compare that with the screenshot below showing the security number highlighted on the front of the card when American Express is selected:
It’s a simple feature really, but nicely implemented.
Recommended Reading for 2009-09-21
- 5 ways to grow great developers instead of desperately looking for them
via Team Leadership
- Things to ask before you redo your website
via Seth’s Blog
- The priority list
via Seth’s Blog
- Tip/Trick: Increase your VS screen real estate by disabling HTML Navigation Bar
via ScottGu’s Blog
- How to find hidden problems in your project before it’s too late
via Team Leadership
How To Reset Your SubSonic 3 ActiveRecord Test Repository For Each Unit Test
When writing unit tests with SubSonic’s new built-in testing for ActiveRecord don’t forget that each time you call the Setup() method on your ActiveRecord object it adds records to any that have already been created. For example:
[Test]
public void Foo_Bar() {
Foo.Setup(10);
Assert.AreEqual(10, Foo.All().Count());
}
[Test]
public void Bar_Foo() {
Foo.Setup(10);
// This will fail: Foo.All().Count() will return 20
Assert.AreEqual(10, Foo.All().Count());
}
To reset your test repositories you will need to call the ResetTestRepo() method prior to each test, which can be accomplished easily enough by adding the method call to your test’s [SetUp] method:
[SetUp]
public void SetUp() {
Foo.ResetTestRepo();
}
[Test]
public void Foo_Bar() {
Foo.Setup(10);
Assert.AreEqual(10, Foo.All().Count());
}
[Test]
public void Bar_Foo() {
Foo.Setup(10);
// Now Foo.All().Count() will return 10 and the test will pass
Assert.AreEqual(10, Foo.All().Count());
}
Hopefully this will save you a bit of time, as well as head scratching :p

