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

23 commits

Author SHA1 Message Date
Nate Berkopec
b59db28a6c
CI -> Github actions (#1918) 2019-09-19 19:50:13 +02:00
MSP-Greg
4c8d4d6921 Update test_integration files per PR #1956 (#1965)
* Update test_integration files per PR #1956

test_integration_cluster.rb

Request handling during server TERM - two tests

`#test_term_closes_listeners_tcp`
`#test_term_closes_listeners_unix`

using `#term_closes_listeners`

Send requests 10 per second.  Send 10, then :TERM server, then send another 30.
No more than 10 should throw Errno::ECONNRESET.

Request handling during phased restart - two tests

`#test_usr1_all_respond_tcp`
`#test_usr1_all_respond_unix`

using `#usr1_all_respond`

Send requests 1 per second.  Send 1, then :USR1 server, then send another 24.
All should be responded to, and at least three workers should be used

Stuck worker tests - two tests

`#test_stuck_external_term_spawn`
Tests whether externally TERM'd 'stuck' workers are proper re-spawned.

`#test_stuck_phased_restart`
Tests whether 'stuck' workers are properly shutdown during phased-restart.

helper files/methods changes

1. helper file changes to allow binding to TCP or UNIX, see kwarg unix:
2. Skip on Windows for signal TERM

* Misc updates, debug output, cleanup

* Add comments

* fix test_int_signal_with_background_thread_in_jruby per review

* TestIntegrationCluster#term_closes_listeners - add interleaved assert

* cluster.rb - remove duplicate Worker#term? method
2019-09-19 19:37:53 +02:00
Nate Berkopec
e864e28b13
Launcher test cleanup (#1966)
* Add no-bundler skip

* Remove unnecessary test requires

* Little bit of launcher test cleanup
2019-09-13 16:44:02 +00:00
Nate Berkopec
2ae66ce61c
Add ignored assertion (#1960)
* Add ignored assertion

* Add Greg's skip-port-3307 patch
2019-09-11 15:14:11 +00:00
MSP-Greg
d4fd8e2ef6 test/helper.rb - add darwin to TestSkips logic (#1933) 2019-08-26 17:21:00 +00:00
MSP-Greg
67be653e10 tests - clean up - three commits (#1903)
* tests - cleanup rackup folder, add sleep.ru, add helpers/app.rb

* tests - change nextport to UniquePort.call, remove nextport, mutex

clean up, mutex removes port issues with parallel testing

* test_integration.rb - make UNIXSocket file names unique
2019-08-12 03:32:46 -07:00
Nate Berkopec
9f4edf4c66
Cleanup tests, parallelize a few (#1850)
+ Some tests getting frozen_string_literal
+ Remove unneccessary bundler setup
+ Fewer/tighter sleeps
2019-07-27 09:47:19 -07:00
Nate Berkopec
4c85facff3
Test cleanup and parallelization (#1846)
* Add frozen string literal everywhere it wasnt already

* Enforce stopgap for tests

* Small amount of integration test cleanup

* Parallelize and freeze Test_app_status

* Big cleanup for test_binder

* Whitespace fix
2019-07-16 18:53:28 -04:00
MSP-Greg
13fef01903 test/helper.rb - skip for #fork, UnixSocket, and signals 2019-02-20 13:50:35 -06:00
MSP-Greg
6a7112d51b Update test files
1. Update skip handling
2. Stability changes
3. Add Ruby & OpenSSL version info output
4. Bypassed SSL tests on DISABLE_SSL ?
2018-09-11 16:31:54 -05:00
David Rodríguez
2154d116c3 Bump versions tested on TravisCI (#1566)
* Bump versions tested on TravisCI

* Remove apparently unused stuff

* Workaround for 2.5.1 Travis/Bundler issue

* Remove no longer needed workaround

* Jruby 9.1.17.0 is out!
2018-05-09 12:28:12 -06:00
Eugene Kenny
342661f05e Use Ruby 2.2.9 on Travis again (#1552)
The test failures we saw after upgrading last time were caused by the
stopgap_13632 gem not being activated on the new version.
2018-04-02 08:03:19 -06:00
schneems
0d28652c3e Avoid hardcoding ports
When a test that boots a server fails it may not properly close out the port. When this happens there is a cascading failure as all other tests that use that port also fail. It becomes hard to find the actual failure reason. This commit uses a new number of every time port is used.
2018-03-20 11:25:26 -05:00
MSP-Greg
7165775970 Combine PR's #1437, 44, & 63 (#1464) 2017-11-20 06:24:02 -07:00
Eileen M. Uchitelle
6714214d57 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.
2017-09-23 05:44:21 +09:00
Nate Berkopec
f4ce5fe9ee Run integration tests in default (#1394)
* Run integration tests in default

* Add retry in CI

* Convert integration test to ruby script for Windows

* Attempt to add finicky tests back

* Possible kinda janky solution

* Only run master branch on travis (syntax fix)

* Don't do integration tests on windows

Can't be bothered to make those tests crossplatform

* Remove join timeouts on read, let the main test timeout do it

* Assert once

* Sigh.
2017-08-16 16:07:15 -06:00
Nikolay Vashchenko
a31a62656d Appveyor CI (#1374)
* appveyour config

* proper platforms for windows

* disabling tests with ssl and interrupts

* excessive ssl setup

* fixed message

* adding info in readme regarding stopgap_13632

* formatting

* trailing spaces
2017-07-27 12:18:58 -06:00
Nikolay Vashchenko
91416134cb temporary workaround for https://bugs.ruby-lang.org/issues/13632 (#1345)
* temporary workaround for https://bugs.ruby-lang.org/issues/13632
Purging interrupt queue if IOError was caught.

* fixing only if mri

* optimization to avoid redundant checks in empty queue

* scoping fix to only affected versions

* serving ruby version from mkmf

* safe invoking for the workaround

* switching to preprocessor vars

* purging queue on runtime error

* rubocop fix

* covering workaround

* improving names

* styling

* rubocop fixes

* improved test reporting

* wording

* condition

* improving comment

* bugfix moved to separate gem: https://rubygems.org/gems/stopgap_13632

* using stopgap_13632 in gemfile to fix the builds

* requiring stopgap for tests
2017-07-19 12:22:36 -06:00
Michael Grosser
0886aef3d0 run tests with bundler since that is what our users run (#1317) 2017-06-09 05:20:03 -07:00
Michael Grosser
65a51b513a make restart via pumactl more robust (#1324) 2017-06-04 05:48:04 -07:00
Michael Grosser
290c22c9ad make tests fast by using readpartial and not blocking read (#1322) 2017-06-03 21:23:55 -07:00
Michael Grosser
febef44844 simplify test shellout and make sure no other version of puma is available so we know our tests work (#1311) 2017-06-02 13:24:01 -07:00
Michael Grosser
9d93a0f62f make test_helper no longer be loaded as a test (#1283)
running `rake` loads all files starting with `test_` which is not supposed to also load the helper,
since the helper should be loaded by each test and is not a test itself.
2017-05-12 12:16:55 -07:00
Renamed from test/test_helper.rb (Browse further)