mini tester ok
This commit is contained in:
10
tester.sh
10
tester.sh
@@ -1,17 +1,11 @@
|
||||
#!/bin/bash
|
||||
|
||||
port=0
|
||||
while [ $port -lt 1024 -o $port -gt 10000 ]; do
|
||||
port=$RANDOM
|
||||
done
|
||||
echo "Running tests on port $port..."
|
||||
|
||||
port=8081
|
||||
clang -Wall -Wextra -Werror mini_serv.c -o mini_serv
|
||||
|
||||
./mini_serv "$port" &
|
||||
nc localhost "$port" &
|
||||
|
||||
for i in {1..30}
|
||||
for i in {1..3000}
|
||||
do
|
||||
nc localhost "$port" &
|
||||
kill -KILL $(pidof nc | tr ' ' '\n' | head -n1)
|
||||
|
||||
Reference in New Issue
Block a user