ice_nine icon indicating copy to clipboard operation
ice_nine copied to clipboard

Add documentation about the NoFreeze System

Open shingara opened this issue 13 years ago • 1 comments

By IRC, dkubb say me we can avoid some freeze on some NameSpace by using the IceNine::Freezer::NoFreeze.

By example if I want not freeze by IceNine all object in RSpec you can do :

module IceNine
  class Freezer
    class RSpec < NoFreeze
    end
  end
end

Can be really usefull in your test.

Maybe a configuration in IceNince can be more easy with a design like :

IceNince.no_freeze_namespace([Rspec, Spec, Mocha])

shingara avatar Nov 29 '12 10:11 shingara

That's a good idea. I may add something like IceNine.no_freeze(*mods). I would then exclude a few common namespaces like Spec, RSpec, Mocha and Test.

dkubb avatar Nov 29 '12 23:11 dkubb