1#!/bin/sh 2 3# 4# Test::LongString Module of perl is needed 5# You can install it with `cpan install Test::LongString` 6# 7 8# 9# Basic Usage. 10# TEST_NGINX_SBIN_PATH=/path/to/nginx/sbin \ 11# ./test.sh 12# 13 14# 15# Custom Backend Server 16# TEST_NGINX_SBIN_PATH=/path/to/nginx/sbin \ 17# TEST_NGINX_BACKENDS_PORT=ip:port \ 18# ./test.sh 19 20TEST_NGINX_SBIN_PATH=${TEST_NGINX_SBIN_PATH:=/path/to/nginx/sbin} 21PATH=$TEST_NGINX_SBIN_PATH:$PATH prove -r t 22 23# 24# The command of @yaoweibin 25# 26# nginx sbin path 27# TEST_NGINX_SBIN_PATH=/home/yaoweibin/nginx/sbin 28 29# 30# basic test with backend www.taobao.com:80 31# 32# PATH=$TEST_NGINX_SBIN_PATH:$PATH prove -r t 33 34# 35# custom test with custom backend 36# 37# TEST_NGINX_BACKENDS_PORT=127.0.0.1:1234 \ 38# PATH=$TEST_NGINX_SBIN_PATH:$PATH prove -r t 39 40 41