Sha256: 50a4bc1b62a070ef0576936fde72e5219da9faa68adf5c3f2cb6a72ccefa19f0
Contents?: true
Size: 542 Bytes
Versions: 56
Compression:
Stored size: 542 Bytes
Contents
require 'bacon' require 'temple' module TestHelper def with_html_safe(flag) String.send(:define_method, :html_safe?) { flag } yield ensure String.send(:undef_method, :html_safe?) if String.method_defined?(:html_safe?) end def grammar_validate(grammar, exp, message) lambda { grammar.validate!(exp) }.should.raise(Temple::InvalidExpression).message.should.equal message end def erb(src, options = {}) Temple::ERB::Template.new(options) { src }.render end end class Bacon::Context include TestHelper end
Version data entries
56 entries across 56 versions & 2 rubygems