Sha256: 979956ba1156c0ae5d60289fa0194152c5cdbf2394a521e13240838d6c6c5969
Contents?: true
Size: 590 Bytes
Versions: 10
Compression:
Stored size: 590 Bytes
Contents
require_relative "../spec_helper" describe "delay_build plugin" do it "does not build rack app until app is called" do app(:delay_build){"a"} app.instance_variable_get(:@app).must_be_nil body.must_equal "a" # Work around minitest bug refute_equal app.instance_variable_get(:@app), nil end it "supports the build! method for backwards compatibility" do app(:delay_build){"a"} body.must_equal "a" c = Class.new do def initialize(_) end def call(_) [200, {}, ["b"]] end end app.use c app.build! body.must_equal "b" end end
Version data entries
10 entries across 10 versions & 1 rubygems