Re: [Radiant] Writing an radius tag extension article - running specs
On Wed, Jun 25, 2008 at 2:26 PM, Chris Parrish <[EMAIL PROTECTED]> wrote: > Use "rake spec:extensions EXT=your_extension_name" to just run the specs for > your extension. It had the same results: http://pastie.org/222128 > By the way, does anyone else think it would be useful to run specific > spec(s) within an extension? > > Perhaps using syntax like: > rake spec:extensions EXT=your_extension_name > FILE=app/controllers/my_controller_spec.rb > > or via grouping like radiant does: > rake spec:extensions:models EXT=your_extension_name > > Just a thought... Well, my preferred process is to execute specs from TextMate with run single example. It's very precise and fast. When I'm doing extension development I rarely run commands from the Radiant root. IMHO, I think that you should be running development type commands from the extension root. Having both options is great though. > Thats quite odd. Are you sure you are running the latest rspec gem? Try a > > gem install rspec I am but it shouldn't be using it. If you look at my pastie, you will see it's using Radiant 6.7's rspec gem. As a quick test I removed that gem and ran the command again with the same results. If I'm not mistaken the spec_helper.rb code will try to use Radiant's rspec first. This is good because you might get errors from rspec on rails about build differences in the gem install rspec. It seems clear that my issues seem to be the exception if not unique. It's a bit troubling as I'm not sure how my system is all that different from other Radiant developers. If anyone has any wisdom on this, please pass it along. :) Cheers, Marty ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant
Re: [Radiant] Writing an radius tag extension article - running specs
Alex Wayne wrote: Thats quite odd. Are you sure you are running the latest rspec gem? Try a gem install rspec -Alex http://beautifulpixel.com I've had troubles using the rSpec gem because Radiant ships with its own version of rSpec and rSpec on Rails. Whenever I tried to use the gem, rSpec on Rails complained that its version didn't match my gem's (even though I used the same release). I've seen comments about this here on the list but I'm not sure that anyone's has found a solution to allow you to use your own installed gem --hence the radiant rake commands to execute radiant's plugged-in versions). -Chris ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant
Re: [Radiant] Writing an radius tag extension article - running specs
Acording to http://rspec.rubyforge.org/rdoc/classes/Spec/Rake/SpecTask.html you can do that rake spec SPEC=path/to/file_spec.rb It works like a charm. -Alex http://beautifulpixel.com On Jun 25, 2008, at 1:26 PM, Chris Parrish wrote: Use "rake spec:extensions EXT=your_extension_name" to just run the specs for your extension. By the way, does anyone else think it would be useful to run specific spec(s) within an extension? Perhaps using syntax like: rake spec:extensions EXT=your_extension_name FILE=app/controllers/ my_controller_spec.rb or via grouping like radiant does: rake spec:extensions:models EXT=your_extension_name Just a thought... -Chris Marty Haught wrote: On Tue, Jun 24, 2008 at 9:15 PM, Alex Wayne <[EMAIL PROTECTED]> wrote: Radiant 0.6.7 generates extensions with a spec directory by default, and no test directory at all. Its all hooked up already for ya. Hi Alex, Yes, I see that but I've run into problems just getting them to run. So I have a fresh Radiant 6.7 install (on Mac Leopard). I used the extension generators as Alex mentioned. I then wrote a really basic spec under spec/models. Here it is: require File.dirname(__FILE__) + '/../spec_helper' describe 'SimpleTest' do it 'should just pass' do true.should be_true end end I then drop to terminal and run rake spec from the extension's root. Here's the output I get: http://pastie.org/222063 Even though all I have is a single example, it's picking up all sorts of other tests that fail. Has no one else seen this? Thoughts? Cheers, Marty ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant
Re: [Radiant] Writing an radius tag extension article - running specs
Chris Parrish wrote: Use "rake spec:extensions EXT=your_extension_name" to just run the specs for your extension. Oh, and you run it from the project's root - not the extension's. -Chris ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant
Re: [Radiant] Writing an radius tag extension article - running specs
Thats quite odd. Are you sure you are running the latest rspec gem? Try a gem install rspec -Alex http://beautifulpixel.com On Jun 25, 2008, at 12:24 PM, Marty Haught wrote: On Tue, Jun 24, 2008 at 9:15 PM, Alex Wayne <[EMAIL PROTECTED]> wrote: Radiant 0.6.7 generates extensions with a spec directory by default, and no test directory at all. Its all hooked up already for ya. Hi Alex, Yes, I see that but I've run into problems just getting them to run. So I have a fresh Radiant 6.7 install (on Mac Leopard). I used the extension generators as Alex mentioned. I then wrote a really basic spec under spec/models. Here it is: require File.dirname(__FILE__) + '/../spec_helper' describe 'SimpleTest' do it 'should just pass' do true.should be_true end end I then drop to terminal and run rake spec from the extension's root. Here's the output I get: http://pastie.org/222063 Even though all I have is a single example, it's picking up all sorts of other tests that fail. Has no one else seen this? Thoughts? Cheers, Marty ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant
Re: [Radiant] Writing an radius tag extension article - running specs
Use "rake spec:extensions EXT=your_extension_name" to just run the specs for your extension. By the way, does anyone else think it would be useful to run specific spec(s) within an extension? Perhaps using syntax like: rake spec:extensions EXT=your_extension_name FILE=app/controllers/my_controller_spec.rb or via grouping like radiant does: rake spec:extensions:models EXT=your_extension_name Just a thought... -Chris Marty Haught wrote: On Tue, Jun 24, 2008 at 9:15 PM, Alex Wayne <[EMAIL PROTECTED]> wrote: Radiant 0.6.7 generates extensions with a spec directory by default, and no test directory at all. Its all hooked up already for ya. Hi Alex, Yes, I see that but I've run into problems just getting them to run. So I have a fresh Radiant 6.7 install (on Mac Leopard). I used the extension generators as Alex mentioned. I then wrote a really basic spec under spec/models. Here it is: require File.dirname(__FILE__) + '/../spec_helper' describe 'SimpleTest' do it 'should just pass' do true.should be_true end end I then drop to terminal and run rake spec from the extension's root. Here's the output I get: http://pastie.org/222063 Even though all I have is a single example, it's picking up all sorts of other tests that fail. Has no one else seen this? Thoughts? Cheers, Marty ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant
[Radiant] Writing an radius tag extension article - running specs
On Tue, Jun 24, 2008 at 9:15 PM, Alex Wayne <[EMAIL PROTECTED]> wrote: > Radiant 0.6.7 generates extensions with a spec directory by default, and no > test directory at all. Its all hooked up already for ya. Hi Alex, Yes, I see that but I've run into problems just getting them to run. So I have a fresh Radiant 6.7 install (on Mac Leopard). I used the extension generators as Alex mentioned. I then wrote a really basic spec under spec/models. Here it is: require File.dirname(__FILE__) + '/../spec_helper' describe 'SimpleTest' do it 'should just pass' do true.should be_true end end I then drop to terminal and run rake spec from the extension's root. Here's the output I get: http://pastie.org/222063 Even though all I have is a single example, it's picking up all sorts of other tests that fail. Has no one else seen this? Thoughts? Cheers, Marty ___ Radiant mailing list Post: Radiant@radiantcms.org Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant