| # Copyright 2020 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. |
| |
| description "Chromium OS cryptohome D-Bus performance test service." |
| author "chromium-os-dev@chromium.org" |
| |
| start on starting cryptohomed |
| stop on stopping cryptohomed |
| |
| oom score -100 |
| |
| env RESULT_FOLDER_PATH="/tmp" |
| |
| script |
| |
| execution_time() { |
| local start_time=$(date +%s%N) |
| $@ >/dev/null 2>/dev/null |
| echo $((`date +%s%N` - $start_time)) |
| } |
| |
| execution_time /usr/bin/gdbus wait --system org.chromium.UserDataAuth \ |
| > $RESULT_FOLDER_PATH/userdataauth_dbus_time |
| |
| end script |