Sha256: 38279ec4a3b91d73270f6b40c0f0c33e39be396325726fccc9da079f506629d8
Contents?: true
Size: 685 Bytes
Versions: 26
Compression:
Stored size: 685 Bytes
Contents
# before hook for Cucumber Before do PaperTrail.enabled = false PaperTrail.enabled_for_controller = true PaperTrail.whodunnit = nil PaperTrail.controller_info = {} if defined? Rails end module PaperTrail module Cucumber # Helper method for enabling PT in Cucumber features. module Extensions # :call-seq: # with_versioning # # enable versioning for specific blocks def with_versioning was_enabled = ::PaperTrail.enabled? ::PaperTrail.enabled = true begin yield ensure ::PaperTrail.enabled = was_enabled end end end end end World PaperTrail::Cucumber::Extensions
Version data entries
26 entries across 25 versions & 2 rubygems