Issue when run my specs in Textmate but not in terminal

Hello, I’m experiencing a weird behavior that I cant find the
solution. My specs that depends on Factory Girl with attachment only
works in command line and not in Textmate with Command+R or Command
+Shift+R.

My app uses rspec 1.3, rspec-rails 1.3.2, factory-girl 1.2.4 and Rails
2.3.5 with paperclip.

Right now I have a simple factory:

Factory.define(:product) do |p|
p.display_name “Things for iPhone”
p.price 9.99
p.attach “icon”, “spec/fixtures/images/app_icon.png”, “image/
png”
end

The attach method above is defined in the same way as below (in a
initializer file):

Any time that I try use the factory above my specs fail with this
message:

Validation failed: Icon /var/folders/CT/CT5WXMvBHIWX2jTklhOUh++++TI/-
Tmp-/stream20100622-9804-1ynydgk-0 is not recognized by the ‘identify’
command.

Somebody have any idea of what it can be?

Thanks a lot.

Fixed, the problem was the path of my textmate. The solution is open
preferences, go to advanced/shell variables and make sure that your
PATH entry includes the path of your imagemagick (in my casa, with
homebrew is /usr/local/bin).