Sha256: 8cf70f28e69c98cab5073049ae6c10eaa240c864e605cf42432fc30d0f6302a5
Contents?: true
Size: 965 Bytes
Versions: 1
Compression:
Stored size: 965 Bytes
Contents
# frozen_string_literal: true ENV['RACK_ENV'] = 'test' require 'bundler/setup' require 'warning' # Ignore all warnings in Gem dependencies Gem.path.each { |path| Warning.ignore(//, path) } require 'dotenv' require 'test/unit' require 'contest' require 'rack/test' require_relative 'support/rack_helpers' require_relative '../app' Dotenv.load module Test module Unit class TestCase # Syntactic sugar for defining a memoized helper method. # def self.let(name, &block) ivar = "@#{name}" class_eval do define_method(name) do if instance_variable_defined?(ivar) instance_variable_get(ivar) else value = instance_eval(&block) instance_variable_set(ivar, value) end end end end end end end module Rack module Test class TestCase < ::Test::Unit::TestCase include RackHelpers end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
hoboken-0.9.0 | lib/hoboken/templates/test/test_helper.rb.tt |