SFDC API 24.0 test failure issue

Yesterday I was experiencing a weird issue. My SFDC API Test Failed.For a new requirement we did development in our DEV environment…We wrote new test methods and we thought the work is done :)…
However, there were Null Pointer Exceptionswhen we ran the test methods.
And it was pointing to the custom settings….we doubled checked and confirmed that the custom setting had the default values. Also, it was accessible to anyone (public).

After some time I realized that the test method API version was 24.0.. I changed it to 23.0 and there were no errors 🙂

Edit – SFDC has introduced test classes not to access data directly with API 24. Even though it is a good move , I would like to access certain info by default like custom settings, and Pricebook. But there is always an option to use @istest(seealldata=true) to access live data.

http://boards.developerforce.com/t5/General-Development/Custom-setting-not-accessible-from-test-class/m-p/399669#M66636