Sha256: aa191d6a229d58bd06bc4efc9ed305ca0769dd1ab3ed41b5c48c4d2f0a3ae459
Contents?: true
Size: 457 Bytes
Versions: 1
Compression:
Stored size: 457 Bytes
Contents
module Helpers def using_test_classes around( :all ) do |example| classes_before_examples = Object.constants yield classes_after_examples = Object.constants classes_created_by_block = classes_after_examples - classes_before_examples example.run classes_created_by_block.each do |klass| Object.send(:remove_const, klass) end end end alias_method :using_test_class, :using_test_classes end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
fortnox-api-0.1.0 | spec/support/helpers/dummy_class_helper.rb |