[PATCH] Add -N or --no-default-middleware option.

Eric Wong normalperson at yhbt.net
Tue Jan 29 04:02:20 UTC 2013

Eric Wong <normalperson at yhbt.net> wrote:
> Lin Jen-Shin <godfat at godfat.org> wrote:
> > +  opts.on("-N", "--no-default-middleware",
> > +          "no default middleware even if RACK_ENV is development") do |e|
> RACK_ENV=deployment also loads middleware, so I think it's more accurate
> with:
> 	do not load middleware implied by RACK_ENV
> This also puts us back within the 80-column limit imposed by "test_help"
> in test/exec/test_exec.rb

Heh, turns out there's a bug in test_exec.rb (but I still don't think
mentioning "development" for this help is correct)

>From ee3ada3c697311ab0a799fcdc492ae062e7d5128 Mon Sep 17 00:00:00 2001
From: Eric Wong <normalperson at yhbt.net>
Date: Tue, 29 Jan 2013 03:56:16 +0000
Subject: [PATCH] test_exec: do not count '\n' as column width

This off-by-one error was incorrectly rejecting a line which
would've been readable without wrapping on an 80-column terminal.
 test/exec/test_exec.rb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/test/exec/test_exec.rb b/test/exec/test_exec.rb
index 1cee2b7..10a1bae 100644
--- a/test/exec/test_exec.rb
+++ b/test/exec/test_exec.rb
@@ -323,6 +323,7 @@ EOF
     # mobile phone or netbook on a slow connection :)
     assert lines.size <= 24, "help height fits in an ANSI terminal window"
     lines.each do |line|
+      line.chomp!
       assert line.size <= 80, "help width fits in an ANSI terminal window"

More information about the mongrel-unicorn mailing list