• Home
  • Raw
  • Download

Lines Matching +full:test +full:- +full:license

4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
11 # distributed under the License is distributed on an "AS IS" BASIS,
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
16 set -e
19 echo "Downloading latest copy of test data"
21 LATEST_ZIP="$(cat tools/install-build-deps | grep -o 'https://.*/perfetto/test-data-.*.zip')"
22 curl -o /tmp/latest-test-data.zip $LATEST_ZIP
25 echo "Extracting test data to temp folder"
27 rm -rf /tmp/latest-test-data 2>/dev/null
28 unzip /tmp/latest-test-data.zip -d /tmp/latest-test-data
33 cp $1 /tmp/latest-test-data
38 NEW_TEST_DATA="test-data-$(date +%Y%m%d-%H%M%S).zip"
40 cd /tmp/latest-test-data
41 zip -r /tmp/$NEW_TEST_DATA *
52 gsutil acl ch -u AllUsers:R gs://perfetto/$NEW_TEST_DATA
55 echo "SHA-256 of file $NEW_TEST_DATA is"
56 NEW_SHA=$(shasum -a 256 /tmp/$NEW_TEST_DATA | cut -c1-64)
62 rm -r /tmp/latest-test-data
63 rm /tmp/latest-test-data.zip
67 echo "Updating tools/install-build-deps"
70 OLD_SHA=$(cat tools/install-build-deps | grep '/test-data-.*.zip' -A1 | tail -n1 | egrep -o '[a-f0-
72 # Cannot easily use sed -i, it has different syntax on Linux vs Mac.
73 cat tools/install-build-deps \
74 | sed -e "s|/test-data-.*.zip|/$NEW_TEST_DATA|g" \
75 | sed -e "s|$OLD_SHA|$NEW_SHA|g" \
76 > tools/install-build-deps.tmp
78 mv -f tools/install-build-deps.tmp tools/install-build-deps
79 chmod 755 tools/install-build-deps