In the _spec.rb file, I configure an exception filter, for example:
RSpec.configure do |config|
and then in the file that I am doing
describe :get_items_by_client, :svr1 => :available do
to prevent the test from running if the server is unavailable.
Everything works fine if I only run the spec file. However, I have similar code in another file that controls the tests that access the other server, and when I run them all, only I see that each server check is performed (do I have the code "serverX_available?"), But only one test suite is excluded (although no server is available).
I'm starting to think that you can have only one exception filter, but I can find any documents anywhere that talk about it. Is this possible for every file? I can have one complex filter in the support file, but how can I enable it when I execute only one specification file?
Ideally, I would like to find a form that works for each file, but let me do the accessibility check once, as this is a somewhat expensive test, and I have a few examples in the test that are controlled by this.
bill selig
source share