16f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins/*
26f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * Copyright (C) 2016 The Android Open Source Project
36f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins *
46f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * Licensed under the Apache License, Version 2.0 (the "License");
56f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * you may not use this file except in compliance with the License.
66f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * You may obtain a copy of the License at
76f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins *
86f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins *      http://www.apache.org/licenses/LICENSE-2.0
96f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins *
106f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * Unless required by applicable law or agreed to in writing, software
116f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * distributed under the License is distributed on an "AS IS" BASIS,
126f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
136f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * See the License for the specific language governing permissions and
146f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins * limitations under the License.
156f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins */
166f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins
179aec926f866f54a311bd898b5f51188f9890a357James Hawkins#include "metricslogger/metrics_logger.h"
186f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins
199aec926f866f54a311bd898b5f51188f9890a357James Hawkins#include <gtest/gtest.h>
20ff2dcd9af994a23ed483939a416b48bdc10eefd5Mark Salyzyn
219aec926f866f54a311bd898b5f51188f9890a357James HawkinsTEST(MetricsLoggerTest, AddSingleBootEvent) {
22b63072e4d029ee7a0038a0d2f053f70c5fe8b33eRuchi Kandoi    android::metricslogger::LogHistogram("test_event", 42);
23b63072e4d029ee7a0038a0d2f053f70c5fe8b33eRuchi Kandoi    // TODO(jhawkins): Verify the EventLog is updated.
24b63072e4d029ee7a0038a0d2f053f70c5fe8b33eRuchi Kandoi}
25b63072e4d029ee7a0038a0d2f053f70c5fe8b33eRuchi Kandoi
26b63072e4d029ee7a0038a0d2f053f70c5fe8b33eRuchi KandoiTEST(MetricsLoggerTest, AddCounterVal) {
27b63072e4d029ee7a0038a0d2f053f70c5fe8b33eRuchi Kandoi    android::metricslogger::LogCounter("test_count", 10);
286f28299d0d10a7c397d563dc8293dacf6acadc04James Hawkins}
29