rsim / ruby-plsql-spec

Oracle PL/SQL unit testing with Ruby
MIT License
68 stars 25 forks source link

RSpec 2.6.0 deprecation warning #8

Closed searls closed 8 years ago

searls commented 13 years ago

RSpec 2.6.0 is giving this warning when I run my specs:

*****************************************************************
DEPRECATION WARNING: you are using deprecated behaviour that will
be removed from RSpec 3.

You have set some configuration options after an example group has
already been defined.  In RSpec 3, this will not be allowed.  All
configuration should happen before the first example group is
defined.  The configuration is happening at:

  /path/to/my/project/spec/spec_helper.rb:50
*****************************************************************

This refers to this generated block:

RSpec.configure do |config|
  config.before(:each) do
    database_connections.each do |name|
      plsql(name).savepoint "before_each"
    end
  end
  config.after(:each) do
    # Always perform rollback to savepoint after each test
    database_connections.each do |name|
      plsql(name).rollback_to "before_each"
    end
  end
  config.after(:all) do
    # Always perform rollback after each describe block
    database_connections.each do |name|
      plsql(name).rollback
    end
  end
end

Thoughts?

rsim commented 13 years ago

I do not have such warnings. Can you ensure that you are not requiring spec_helper.rb twice? (Maybe using different path names to this file) Or maybe try to add some debugging message before this code block to see if it is executed once or several times.

searls commented 13 years ago

Indeed, only one of several workstations is seeing the error. I'll look into it in more detail the next time I see it.

On Jul 20, 2011, at 9:53, rsim reply@reply.github.com wrote:

I do not have such warnings. Can you ensure that you are not requiring spec_helper.rb twice? (Maybe using different path names to this file) Or maybe try to add some debugging message before this code block to see if it is executed once or several times.

Reply to this email directly or view it on GitHub: https://github.com/rsim/ruby-plsql-spec/issues/8#issuecomment-1615534

jgebal commented 9 years ago

Is it still valid after recent updates or can we close this one?

jgebal commented 8 years ago

if we're unable to reproduce, and no one complains, can it be closed?

javornikolov commented 8 years ago

I don't see warnings either, using rspec 3.4. I'm closing the issue...