[Radiant] Extension Testing troubles

Daniel Sheppard daniels at thegroggysquirrel.com
Thu Nov 8 20:28:55 CST 2007


> I'm having trouble writing unit tests for a Radiant extension. I've  
> created fixtures for layouts, pages and page_parts, which are pasted  
> below. In my unit test, I find that if I call:
> 
> @page = pages(:homepage)
> 
> the tests work. Whereas if I try:
> 
> @page = pages(:lazypage)
> 
> I get an error:
> 
> StandardError: No fixture with name 'lazypage' found for table 'pages'
> 
> There is a lazypage in my pages fixture, so I don't know why it does  
> this. Any ideas?

There was a problem in the fixture loading code where any syntax problems in the yaml file would be silently ignored. If you update
to the latest trunk, you might get a more meaningful error message.

Dan




More information about the Radiant mailing list