forked from bitshares/bitshares-core
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from bitshares/release
Merge Branch Release
- Loading branch information
Showing
340 changed files
with
46,078 additions
and
9,639 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
name: macOS | ||
on: [ push, pull_request ] | ||
env: | ||
CCACHE_COMPRESS: exists means true | ||
CCACHE_SLOPPINESS: include_file_ctime,include_file_mtime,time_macros | ||
jobs: | ||
build-osx: | ||
name: Build and test in macOS | ||
strategy: | ||
matrix: | ||
os: [macos-10.15, macos-11.0] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Install dependencies | ||
run: | | ||
brew install autoconf automake libtool | ||
brew install ccache | ||
brew install parallel | ||
brew install bitshares/boost/[email protected] | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Configure | ||
run: | | ||
mkdir -p _build | ||
pushd _build | ||
cmake -D CMAKE_BUILD_TYPE=Release \ | ||
-D CMAKE_C_COMPILER_LAUNCHER=ccache \ | ||
-D CMAKE_CXX_COMPILER_LAUNCHER=ccache \ | ||
-D BOOST_ROOT=/usr/local/opt/[email protected] \ | ||
-D OPENSSL_ROOT_DIR=/usr/local/opt/openssl \ | ||
.. | ||
- name: Load Cache | ||
uses: actions/cache@v2 | ||
with: | ||
path: ccache | ||
key: ccache-${{ matrix.os }}-${{ github.ref }}-${{ github.sha }} | ||
restore-keys: | | ||
ccache-${{ matrix.os }}-${{ github.ref }}- | ||
ccache-${{ matrix.os }}- | ||
- name: Build | ||
run: | | ||
export CCACHE_DIR="$GITHUB_WORKSPACE/ccache" | ||
mkdir -p "$CCACHE_DIR" | ||
make -j 2 -C _build witness_node cli_wallet app_test cli_test chain_test | ||
df -h | ||
- name: Unit-Tests | ||
run: | | ||
_build/tests/app_test -l test_suite | ||
libraries/fc/tests/run-parallel-tests.sh _build/tests/chain_test -l test_suite | ||
_build/tests/cli_test -l test_suite | ||
df -h | ||
- name: Quick test for program arguments | ||
run: | | ||
_build/programs/witness_node/witness_node --version | ||
_build/programs/witness_node/witness_node --help | ||
if _build/programs/witness_node/witness_node --bad-arg ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
if _build/programs/witness_node/witness_node --plugins "account_history elasticsearch" ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
if _build/programs/witness_node/witness_node --rpc-endpoint --plugins "witness"; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
_build/programs/cli_wallet/cli_wallet --version | ||
_build/programs/cli_wallet/cli_wallet --help | ||
_build/programs/cli_wallet/cli_wallet --suggest-brain-key | ||
if _build/programs/cli_wallet/cli_wallet --bad-arg ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
- name: Node-Test | ||
run: | | ||
df -h | ||
pushd _build | ||
../programs/build_helpers/run-node-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,139 @@ | ||
name: Ubuntu Debug | ||
on: [ push, pull_request ] | ||
env: | ||
CCACHE_COMPRESS: exists means true | ||
CCACHE_SLOPPINESS: include_file_ctime,include_file_mtime,time_macros | ||
jobs: | ||
test-debug: | ||
name: Build and test in Debug mode | ||
strategy: | ||
matrix: | ||
os: [ ubuntu-16.04, ubuntu-18.04, ubuntu-20.04 ] | ||
runs-on: ${{ matrix.os }} | ||
services: | ||
elasticsearch: | ||
image: docker://elasticsearch:7.10.1 | ||
options: --env discovery.type=single-node --publish 9200:9200 --publish 9300:9300 | ||
steps: | ||
- name: Install dependencies | ||
run: | | ||
df -h | ||
sudo apt-get update | ||
openssl_ver=`sudo apt-cache madison openssl | grep xenial-updates | awk '{print $3}'` | ||
libssl_ver=`sudo apt-cache madison libssl-dev | grep xenial-updates | awk '{print $3}'` | ||
[ -n "${openssl_ver}" ] && [ -n "${libssl_ver}" ] && \ | ||
sudo apt-get install -y --allow-downgrades openssl=${openssl_ver} libssl-dev=${libssl_ver} | ||
sudo apt-get install -y \ | ||
ccache \ | ||
parallel \ | ||
libboost-thread-dev \ | ||
libboost-iostreams-dev \ | ||
libboost-date-time-dev \ | ||
libboost-system-dev \ | ||
libboost-filesystem-dev \ | ||
libboost-program-options-dev \ | ||
libboost-chrono-dev \ | ||
libboost-test-dev \ | ||
libboost-context-dev \ | ||
libboost-regex-dev \ | ||
libboost-coroutine-dev \ | ||
libcurl4-openssl-dev | ||
sudo apt-get auto-remove -y | ||
sudo apt-get clean -y | ||
df -h | ||
sudo du -hs /mnt/* | ||
sudo ls -alr /mnt/ | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Configure | ||
run: | | ||
pwd | ||
df -h . | ||
mkdir -p _build | ||
sudo mkdir -p /_build/libraries /_build/programs /mnt/_build/tests | ||
sudo chmod a+rwx /_build/libraries /_build/programs /mnt/_build/tests | ||
ln -s /_build/libraries _build/libraries | ||
ln -s /_build/programs _build/programs | ||
ln -s /mnt/_build/tests _build/tests | ||
sudo ln -s /_build/libraries /mnt/_build/libraries | ||
sudo ln -s /_build/programs /mnt/_build/programs | ||
sudo ln -s /mnt/_build/tests /_build/tests | ||
ls -al _build | ||
pushd _build | ||
export -n BOOST_ROOT BOOST_INCLUDEDIR BOOST_LIBRARYDIR | ||
cmake -D CMAKE_BUILD_TYPE=Debug \ | ||
-D CMAKE_CXX_OUTPUT_EXTENSION_REPLACE=ON \ | ||
-D CMAKE_C_COMPILER=gcc \ | ||
-D CMAKE_C_COMPILER_LAUNCHER=ccache \ | ||
-D CMAKE_CXX_COMPILER=g++ \ | ||
-D CMAKE_CXX_COMPILER_LAUNCHER=ccache \ | ||
.. | ||
popd | ||
- name: Load Cache | ||
uses: actions/cache@v2 | ||
with: | ||
path: ccache | ||
key: ccache-debug-${{ matrix.os }}-${{ github.ref }}-${{ github.sha }} | ||
restore-keys: | | ||
ccache-debug-${{ matrix.os }}-${{ github.ref }}- | ||
ccache-debug-${{ matrix.os }}- | ||
- name: Build | ||
run: | | ||
export CCACHE_DIR="$GITHUB_WORKSPACE/ccache" | ||
mkdir -p "$CCACHE_DIR" | ||
df -h | ||
make -j 2 -C _build chain_test | ||
make -j 2 -C _build cli_test | ||
make -j 2 -C _build cli_wallet | ||
make -j 2 -C _build witness_node | ||
make -j 2 -C _build | ||
df -h | ||
du -hs _build/libraries/* _build/programs/* _build/tests/* | ||
du -hs _build/* | ||
du -hs /_build/* | ||
- name: Unit-Tests | ||
run: | | ||
_build/tests/app_test -l test_suite | ||
df -h | ||
curl -XPUT -H "Content-Type: application/json" http://localhost:9200/_cluster/settings \ | ||
-d '{ "transient": { "cluster.routing.allocation.disk.threshold_enabled": false } }' | ||
echo | ||
_build/tests/es_test -l test_suite | ||
df -h | ||
libraries/fc/tests/run-parallel-tests.sh _build/tests/chain_test -l test_suite | ||
_build/tests/cli_test -l test_suite | ||
df -h | ||
- name: Quick test for program arguments | ||
run: | | ||
_build/programs/witness_node/witness_node --version | ||
_build/programs/witness_node/witness_node --help | ||
if _build/programs/witness_node/witness_node --bad-arg ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
if _build/programs/witness_node/witness_node --plugins "account_history elasticsearch" ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
if _build/programs/witness_node/witness_node --rpc-endpoint --plugins "witness"; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
_build/programs/cli_wallet/cli_wallet --version | ||
_build/programs/cli_wallet/cli_wallet --help | ||
_build/programs/cli_wallet/cli_wallet --suggest-brain-key | ||
if _build/programs/cli_wallet/cli_wallet --bad-arg ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
- name: Node-Test | ||
run: | | ||
df -h | ||
pushd _build | ||
../programs/build_helpers/run-node-test | ||
df -h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,115 @@ | ||
name: Ubuntu Release | ||
on: [ push, pull_request ] | ||
env: | ||
CCACHE_COMPRESS: exists means true | ||
CCACHE_SLOPPINESS: include_file_ctime,include_file_mtime,time_macros | ||
jobs: | ||
test-release: | ||
name: Build and test in Release mode | ||
strategy: | ||
matrix: | ||
os: [ ubuntu-16.04, ubuntu-18.04, ubuntu-20.04 ] | ||
runs-on: ${{ matrix.os }} | ||
services: | ||
elasticsearch: | ||
image: docker://elasticsearch:7.10.1 | ||
options: --env discovery.type=single-node --publish 9200:9200 --publish 9300:9300 | ||
steps: | ||
- name: Install dependencies | ||
run: | | ||
sudo apt-get update | ||
openssl_ver=`sudo apt-cache madison openssl | grep xenial-updates | awk '{print $3}'` | ||
libssl_ver=`sudo apt-cache madison libssl-dev | grep xenial-updates | awk '{print $3}'` | ||
[ -n "${openssl_ver}" ] && [ -n "${libssl_ver}" ] && \ | ||
sudo apt-get install -y --allow-downgrades openssl=${openssl_ver} libssl-dev=${libssl_ver} | ||
sudo apt-get install -y \ | ||
ccache \ | ||
parallel \ | ||
libboost-thread-dev \ | ||
libboost-iostreams-dev \ | ||
libboost-date-time-dev \ | ||
libboost-system-dev \ | ||
libboost-filesystem-dev \ | ||
libboost-program-options-dev \ | ||
libboost-chrono-dev \ | ||
libboost-test-dev \ | ||
libboost-context-dev \ | ||
libboost-regex-dev \ | ||
libboost-coroutine-dev \ | ||
libcurl4-openssl-dev | ||
sudo apt-get auto-remove -y | ||
sudo apt-get clean -y | ||
df -h | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
- name: Configure | ||
run: | | ||
mkdir -p _build | ||
pushd _build | ||
export -n BOOST_ROOT BOOST_INCLUDEDIR BOOST_LIBRARYDIR | ||
cmake -D CMAKE_BUILD_TYPE=Release \ | ||
-D CMAKE_CXX_OUTPUT_EXTENSION_REPLACE=ON \ | ||
-D CMAKE_C_COMPILER=gcc \ | ||
-D CMAKE_C_COMPILER_LAUNCHER=ccache \ | ||
-D CMAKE_CXX_COMPILER=g++ \ | ||
-D CMAKE_CXX_COMPILER_LAUNCHER=ccache \ | ||
.. | ||
popd | ||
- name: Load Cache | ||
uses: actions/cache@v2 | ||
with: | ||
path: ccache | ||
key: ccache-release-${{ matrix.os }}-${{ github.ref }}-${{ github.sha }} | ||
restore-keys: | | ||
ccache-release-${{ matrix.os }}-${{ github.ref }}- | ||
ccache-release-${{ matrix.os }}- | ||
- name: Build | ||
run: | | ||
export CCACHE_DIR="$GITHUB_WORKSPACE/ccache" | ||
mkdir -p "$CCACHE_DIR" | ||
make -j 2 -C _build | ||
df -h | ||
- name: Unit-Tests | ||
run: | | ||
_build/tests/app_test -l test_suite | ||
curl -XPUT -H "Content-Type: application/json" http://localhost:9200/_cluster/settings \ | ||
-d '{ "transient": { "cluster.routing.allocation.disk.threshold_enabled": false } }' | ||
echo | ||
_build/tests/es_test -l test_suite | ||
libraries/fc/tests/run-parallel-tests.sh _build/tests/chain_test -l test_suite | ||
_build/tests/cli_test -l test_suite | ||
df -h | ||
- name: Quick test for program arguments | ||
run: | | ||
_build/programs/witness_node/witness_node --version | ||
_build/programs/witness_node/witness_node --help | ||
if _build/programs/witness_node/witness_node --bad-arg ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
if _build/programs/witness_node/witness_node --plugins "account_history elasticsearch" ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
if _build/programs/witness_node/witness_node --rpc-endpoint --plugins "witness"; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
_build/programs/cli_wallet/cli_wallet --version | ||
_build/programs/cli_wallet/cli_wallet --help | ||
_build/programs/cli_wallet/cli_wallet --suggest-brain-key | ||
if _build/programs/cli_wallet/cli_wallet --bad-arg ; then \ | ||
echo "Fail: did not get expected error."; false; \ | ||
else \ | ||
echo "Pass: got expected error."; \ | ||
fi | ||
- name: Node-Test | ||
run: | | ||
df -h | ||
pushd _build | ||
../programs/build_helpers/run-node-test | ||
df -h |
Oops, something went wrong.