[ANN] Test::Nginx 0.23 released
Yichun Zhang (agentzh)
agentzh at gmail.com
Sun Apr 6 04:11:15 UTC 2014
Hello!
I've just uploaded Test::Nginx 0.23 to CPAN:
http://search.cpan.org/perldoc?Test::Nginx
It will appear on the CPAN mirror near you in the next few hours or so.
Special thanks go to all our contributors and users :)
Here's the complete change log for this release (compared to the last
CPAN release, 0.22):
* feature: added new section --- response_body_unlike. thanks
Rickey Visinski for the patch.
* feature: allow use of the $ServerPort and $ServerPortForClient
variables in "--- response_headers".
* feature: now we automatically kill the process listening on the
mocked TCP port when we have tried for more than 20 times.
* feature: added new section "--- http09" to Test::Nginx::Socket
to indicate use of HTTP 0.9 requests.
* feature: added support for the $LIBLUA_PATH variable in "---
stap", which evaluates to the absolute path of the liblua*.so
DSO loaded by the nginx server.
* feature: we skipped reading the response body for 101 responses.
* feature: added new section "--- post_main_config" to add custom
top-level configuration snippets right after the http {} block
generated by Test::Nginx.
* feature: added unix domain socket support for tcp_listen. thanks
Jiale Zhi for the patch.
* feature: added new sections "--- grep_error_log" and "---
grep_error_log_out".
* feature: added utility function check_accum_error_log for
checking the accumulated error logs in "--- error_log" and "---
no_error_log".
* feature: added utility Perl function server_port_for_client.
thanks doujiang for the patch.
* feature: added configuration Perl function server_name(). thanks
doujiang for the original patch.
* feature: added new module Test::Nginx::Socket::Lua.
* feature: automatically test if there is any assertion failures
in the nginx error logs.
* feature: when nginx process is gone unexpectedly, we
automatically tail the nginx error log file.
* feature: added the "--- no_check_leak" section to skip test
blocks in the "check leak" testing mode.
* feature: "--- no_error_log" accepts a single Perl Regexp object
now, just like "--- error_log".
* bugfix: Test::Nginx::Socket tried to read response bodies for
304 responses.
* bugfix: we did not try hard enough before killing the nginx
process by force.
* bugfix: improved the error handling when recv() fails on the
HTTP connection.
* bugfix: subtests for "--- tcp_query", "--- tcp_query_len", and
"--- udp_query" disabled test plan checks.
* bugfix: we did not pass the LD_LIBRARY_PATH environment to nginx
when systemtap is used.
* bugfix: "--- error_log" should work on each test request's own
logs only.
* bugfix: server address should default to 127.0.0.1 instead of
"localhost".
* bugfix: made the test skip messages better.
* change: removed "env LUA_PATH" and "env LUA_CPATH" from the
default nginx configuration generated.
* change: set --num-callers=100 to valgrind by default.
* doc: Test::Nginx::Socket: documented the various exported Perl
functions like "run_tests", "repeat_each", and "no_shuffle".
This Perl module provides a test scaffold based on IO::Socket or LWP
for automated testing in Nginx C module or ngx_lua-based Lua library
development.
This class inherits from Test::Base, thus bringing all its declarative
power to the NginxC module testing practices.
Please check out the full documentation on CPAN:
http://search.cpan.org/perldoc?Test::Nginx::Socket
All of our Nginx modules (as well as our lua-resty-* libraries) are
using Test::Nginx to drive their test suites. And it is also driving
my test cluster running on Amazon EC2:
http://qa.openresty.org
Please note that this module is completely different from the
Test::Nginx module created by Maxim Dounin.
The git repository for this Perl module is hosted on GitHub:
https://github.com/agentzh/test-nginx
Have fun!
-agentzh
More information about the nginx-devel
mailing list