mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-16 00:00:07 +01:00

This converts several of the selftests to return a status in their exit code about whether they 'worked'. A small bash script framework is added, with a selftest.sh in the mininmal example dirs that support it, and a ./minimal-examples/selftests.sh script that can be run from the build dir with no args that discovers and runs all the selftest.sh scripts underneath. That is also integrated into travis and the enabled tests must pass now for travis to pass. Travis does not have a modern libuv so it can't run a couple of tests which are nulled out if it sees it's running in travis env.
43 lines
680 B
Bash
Executable file
43 lines
680 B
Bash
Executable file
#!/bin/bash
|
|
|
|
if [ "$COVERITY_SCAN_BRANCH" == 1 ]; then exit; fi
|
|
|
|
if [ "$TRAVIS_OS_NAME" == "linux" ];
|
|
then
|
|
sudo apt-get update -qq
|
|
|
|
if [ "$LWS_METHOD" == "lwsws" ];
|
|
then
|
|
sudo apt-get install -y -qq realpath;
|
|
fi
|
|
|
|
if [ "$LWS_METHOD" == "libev" ];
|
|
then
|
|
sudo apt-get install -y -qq libev-dev;
|
|
fi
|
|
|
|
if [ "$LWS_METHOD" == "libuv" -o "$LWS_METHOD" == "lwsws" ];
|
|
then
|
|
sudo apt-get install -y -qq libuv-dev;
|
|
#libuv1 libuv1-dev;
|
|
fi
|
|
|
|
fi
|
|
|
|
if [ "$TRAVIS_OS_NAME" == "osx" ];
|
|
then
|
|
if [ "$LWS_METHOD" == "libev" ];
|
|
then
|
|
brew update;
|
|
brew install libev;
|
|
fi
|
|
|
|
if [ "$LWS_METHOD" == "libuv" -o "$LWS_METHOD" == "lwsws" ];
|
|
then
|
|
brew update;
|
|
brew install libuv;
|
|
fi
|
|
|
|
fi
|
|
|
|
|