Sha256: 6cf27e8cfd73f42aac601028d86da9c961ace03cb807dede28feaa4c1a54c18a
Contents?: true
Size: 736 Bytes
Versions: 1
Compression:
Stored size: 736 Bytes
Contents
#!/bin/sh . ./test-lib.sh eval $(unused_listen) rtmpfiles unicorn_config curl_out curl_err pid r_err r_out nr_client=30 nr_thread=10 cat > $unicorn_config <<EOF stderr_path "$r_err" stdout_path "$r_out" listen "$listen" pid "$pid" Rainbows! do use :ThreadSpawn worker_connections $nr_thread end EOF rainbows -D t2000.ru -c $unicorn_config wait_for_pid $pid start=$(date +%s) for i in $(awk "BEGIN{for(i=0;i<$nr_client;++i) print i}" </dev/null) do ( curl -sSf http://$listen/$i >> $curl_out 2>> $curl_err ) & done wait echo elapsed=$(( $(date +%s) - $start )) kill $(cat $pid) ! test -s $curl_err test x"$(wc -l < $curl_out)" = x$nr_client nr=$(sort < $curl_out | uniq | wc -l) test "$nr" -eq $nr_client ! grep Error $r_err
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rainbows-0.2.0 | t/t2000-thread-spawn-basic.sh |