Re: [rspec-users] how to include module into shared example group in RSpec 2

2011-06-01 Thread Jarmo Pertman
Done https://github.com/rspec/rspec-core/issues/396 Jarmo On Jun 1, 6:05 pm, David Chelimsky wrote: > On Jun 1, 2011, at 10:05 AM, Jarmo Pertman wrote: > > > Thank you :) > > > Where can i see the differences between #it_should_behave_like, > > #include_context and #include_examples? > > http://

Re: [rspec-users] RSpec 2 not finding specs from subdirectories when trying to run specs from there

2011-06-01 Thread David Chelimsky
On Jun 1, 2011, at 9:57 AM, Jarmo Pertman wrote: > It is indeed related with Windows! > > C:\Users\jarmo\Desktop\minu\projects\Ruby\myproject>rspec spec/subdir > . > > Finished in 0.0045 seconds > 1 example, 0 failures > > C:\Users\jarmo\Desktop\minu\projects\Ruby\myproject>rspec spec\subdir >

Re: [rspec-users] how to include module into shared example group in RSpec 2

2011-06-01 Thread David Chelimsky
On Jun 1, 2011, at 10:05 AM, Jarmo Pertman wrote: > Thank you :) > > Where can i see the differences between #it_should_behave_like, > #include_context and #include_examples? http://relishapp.com/rspec/rspec-core > > Jarmo > > On Jun 1, 5:42 pm, David Chelimsky wrote: >> On Jun 1, 2011, at

Re: [rspec-users] how to include module into shared example group in RSpec 2

2011-06-01 Thread Jarmo Pertman
Thank you :) Where can i see the differences between #it_should_behave_like, #include_context and #include_examples? Jarmo On Jun 1, 5:42 pm, David Chelimsky wrote: > On Jun 1, 2011, at 9:10 AM, Jarmo Pertman wrote: > > > > > > > > > > > Hi! > > > We tried to upgrade our RSpec from 1.3.1 to 2.6

Re: [rspec-users] RSpec 2 not finding specs from subdirectories when trying to run specs from there

2011-06-01 Thread Jarmo Pertman
It is indeed related with Windows! C:\Users\jarmo\Desktop\minu\projects\Ruby\myproject>rspec spec/subdir . Finished in 0.0045 seconds 1 example, 0 failures C:\Users\jarmo\Desktop\minu\projects\Ruby\myproject>rspec spec\subdir No examples found. Finished in 0 seconds 0 examples, 0 failures C:\

Re: [rspec-users] RSpec 2 not finding specs from subdirectories when trying to run specs from there

2011-06-01 Thread Jarmo Pertman
I created a really simple example as shown above and this doesn't work for me - e.g. no spec_helper or .rspec files in use. I'm on Windows, could that be the culprit (it happens on two machines)? Here is some additional output: C:\Users\jarmo\Desktop\minu\projects\Ruby\myproject>tree Folder PATH l

Re: [rspec-users] how to include module into shared example group in RSpec 2

2011-06-01 Thread David Chelimsky
On Jun 1, 2011, at 9:10 AM, Jarmo Pertman wrote: > Hi! > > We tried to upgrade our RSpec from 1.3.1 to 2.6 and are having some > problems. It seems that shared example group includes modules > differently in RSpec 2. > > Consider the following code: > module MyModule > def testing > end > end

Re: [rspec-users] RSpec 2 not finding specs from subdirectories when trying to run specs from there

2011-06-01 Thread Chris Habgood
Try this in your spec helper file: Dir[Rails.root.join("spec/factories/**/*.rb")].each {|f| require f} On Wed, Jun 1, 2011 at 09:14, Jarmo Pertman wrote: > Hi! > > When having a file structure like this: > project > -spec >-subdir > -my_spec.rb > > and then being in directory "project

Re: [rspec-users] RSpec 2 not finding specs from subdirectories when trying to run specs from there

2011-06-01 Thread David Chelimsky
On Jun 1, 2011, at 9:14 AM, Jarmo Pertman wrote: > Hi! > > When having a file structure like this: > project > -spec >-subdir > -my_spec.rb > > and then being in directory "project" and running command `rspec spec` > everything works as expected. If running `rspec spec/subdir` to run >

[rspec-users] how to include module into shared example group in RSpec 2

2011-06-01 Thread Jarmo Pertman
Hi! We tried to upgrade our RSpec from 1.3.1 to 2.6 and are having some problems. It seems that shared example group includes modules differently in RSpec 2. Consider the following code: module MyModule def testing end end shared_examples_for "shared" do include MyModule it "works" do te

[rspec-users] how to include module into shared example group in RSpec 2

2011-06-01 Thread Jarmo Pertman
Hi! We tried to upgrade our RSpec from 1.3.1 to 2.6 and are having some problems. It seems that shared example group includes modules differently in RSpec 2. Consider the following code: module MyModule def testing end end shared_examples_for "shared" do include MyModule it "works" do

[rspec-users] RSpec 2 not finding specs from subdirectories when trying to run specs from there

2011-06-01 Thread Jarmo Pertman
Hi! When having a file structure like this: project -spec -subdir -my_spec.rb and then being in directory "project" and running command `rspec spec` everything works as expected. If running `rspec spec/subdir` to run only specs under spec/subdir then it doesn't work - it finds 0 examp