rspectacular 0.11.0 → 0.11.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,12 +1,14 @@
1
+ require 'singleton'
2
+
1
3
  RSpec.configure do |config|
2
4
  config.around(:each, :singletons => lambda { |v| !!v }) do |example|
3
5
  options = example.metadata[:singletons]
4
- singletons_to_reset = options.respond_to?(:each) ? options : []
6
+ singletons_to_reset = options.respond_to?(:each) ? options : [options]
5
7
 
6
8
  example.run
7
9
 
8
10
  singletons_to_reset.each do |singleton|
9
- singleton.class_variable_set(:@@singleton__instance__, nil)
11
+ Singleton.__init__(singleton)
10
12
  end
11
13
  end
12
14
  end
@@ -1,3 +1,3 @@
1
1
  module RSpectacular
2
- VERSION = '0.11.0'
2
+ VERSION = '0.11.1'
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: rspectacular
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.11.0
5
+ version: 0.11.1
6
6
  platform: ruby
7
7
  authors:
8
8
  - jfelchner