mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-10 12:09:31 +00:00
4d1e9f503b
The recipe will use the newly added --generate-lcov flag to generate a profile, which is then uploaded to codecov.io. The codecov.io uploader is stored in CIPD, and our upload token is kept secure by Secret Manager. To prevent token from being leaked in a log, the token is downloaded and added by a wrapper shell script. BUG=b:239255082 TEST=./recipes.py run build_coverage Change-Id: Ie8197864d9ecc12ebefe81235f2d62bd7342d0c7 Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/3805832 Tested-by: Dennis Kempin <denniskempin@google.com> Reviewed-by: Daniel Verkamp <dverkamp@chromium.org> Commit-Queue: Dennis Kempin <denniskempin@google.com>
20 lines
637 B
Bash
Executable file
20 lines
637 B
Bash
Executable file
#!/usr/bin/env bash
|
|
# Copyright 2022 The Chromium OS Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
# found in the LICENSE file.
|
|
|
|
BUILD_DIR=$(mktemp -d)
|
|
cd "$BUILD_DIR" || exit 1
|
|
|
|
CIPD_ARGS=(
|
|
-pkg-var "description:codecov.io uploader"
|
|
-install-mode copy
|
|
-ref latest
|
|
)
|
|
|
|
CODECOV_URL="https://uploader.codecov.io/v0.2.5/linux/codecov"
|
|
|
|
wget -q "$CODECOV_URL" -O "codecov"
|
|
echo "66cbf87269acc529c87f6ea29395ba329f528e92cfda4fc199eab460123e18b6 codecov" | sha256sum --check --status
|
|
chmod +x codecov
|
|
cipd create -in "." -name "crosvm/codecov/linux-amd64" "${CIPD_ARGS[@]}"
|