steps:
  - command: |
        echo "+++ :hammer: Building" && \
        /usr/bin/cmake -GNinja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_COMPILER=clang++-4.0 -DCMAKE_C_COMPILER=clang-4.0 -DWASM_ROOT=/root/opt/wasm -DOPENSSL_ROOT_DIR=/usr/include/openssl -DBUILD_MONGO_DB_PLUGIN=true -DENABLE_COVERAGE_TESTING=true -DBUILD_DOXYGEN=false && \
        /usr/bin/ninja
        echo "--- :spiral_note_pad: Generating Code Coverage Report" && \
        /usr/bin/ninja EOS_ut_coverage
    label: ":spiral_note_pad: Generate Report"
    agents:
      - "role=linux-coverage"
    artifact_paths: "EOS_ut_coverage/**/*"
    plugins:
      docker#v1.1.1:
        image: "eosio/ci:ubuntu18"
        workdir: /data/job
        environment:
          - BOOST_ROOT=/root/opt/boost_1_66_0
          - OPENSSL_ROOT_DIR=/usr/include/openssl
          - WASM_ROOT=/root/opt/wasm
          - PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/opt/wasm/bin
    timeout: 30

steps:
  - command: |
        echo "+++ :hammer: Building" && \
        /usr/bin/cmake -GNinja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_COMPILER=clang++-4.0 -DCMAKE_C_COMPILER=clang-4.0 -DWASM_ROOT=/root/opt/wasm -DOPENSSL_ROOT_DIR=/usr/include/openssl -DBUILD_MONGO_DB_PLUGIN=true -DENABLE_COVERAGE_TESTING=true -DBUILD_DOXYGEN=false && \
        /usr/bin/ninja
        echo "--- :spiral_note_pad: Generating Code Coverage Report" && \
        /usr/bin/ninja EOS_ut_coverage && \
        tar -pzcf report.tar.gz EOS_ut_coverage/
    label: ":spiral_note_pad: Generate Report"
    agents:
      - "role=linux-coverage"
    artifact_paths: "report.tar.gz"
    plugins:
      docker#v1.1.1:
        image: "eosio/ci:ubuntu18"
        workdir: /data/job
        environment:
          - BOOST_ROOT=/root/opt/boost_1_66_0
          - OPENSSL_ROOT_DIR=/usr/include/openssl
          - WASM_ROOT=/root/opt/wasm
          - PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/opt/wasm/bin
    timeout: 30

Compress report directory before artifacting
Compress report directory before artifacting