1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00

Require puma/events in test helper (#1418)

Moves the require for puma/events from the individual test files and
into the main test helper.

The reason for this was while I was debugging the `test_puma_server.rb`
tests I was getting an error for an uninitialized constant for
`Puma::Event`.

Moving the require from the individual files to the test help means the
`puma/events` will always be included instead of having to remember to
do that. It makes debugging individual tests locally easier.
This commit is contained in:
Eileen M. Uchitelle 2017-09-22 16:44:21 -04:00 committed by Nate Berkopec
parent 459ab19636
commit 6714214d57
6 changed files with 1 additions and 8 deletions

View file

@ -21,6 +21,7 @@ $LOAD_PATH << File.expand_path("../../lib", __FILE__)
Thread.abort_on_exception = true
require "puma"
require "puma/events"
require "puma/detect"
# Either takes a string to do a get request against, or a tuple of [URI, HTTP] where

View file

@ -1,7 +1,6 @@
require_relative "helper"
require "puma/binder"
require "puma/events"
require "puma/puma_http11"
class TestBinder < Minitest::Test

View file

@ -1,7 +1,5 @@
require_relative "helper"
require "puma/events"
class TestEvents < Minitest::Test
def test_null
events = Puma::Events.null

View file

@ -1,7 +1,5 @@
require_relative "helper"
require "puma/events"
class SSLEventsHelper < ::Puma::Events
attr_accessor :addr, :cert, :error

View file

@ -1,6 +1,5 @@
require_relative "helper"
require "puma/events"
require "puma/tcp_logger"
class TestTCPLogger < Minitest::Test

View file

@ -1,7 +1,5 @@
require_relative "helper"
require "puma/events"
class TestTCPRack < Minitest::Test
def setup