1*0a450197SShawn McCarney /**
2*0a450197SShawn McCarney  * Copyright © 2021 IBM Corporation
3*0a450197SShawn McCarney  *
4*0a450197SShawn McCarney  * Licensed under the Apache License, Version 2.0 (the "License");
5*0a450197SShawn McCarney  * you may not use this file except in compliance with the License.
6*0a450197SShawn McCarney  * You may obtain a copy of the License at
7*0a450197SShawn McCarney  *
8*0a450197SShawn McCarney  *     http://www.apache.org/licenses/LICENSE-2.0
9*0a450197SShawn McCarney  *
10*0a450197SShawn McCarney  * Unless required by applicable law or agreed to in writing, software
11*0a450197SShawn McCarney  * distributed under the License is distributed on an "AS IS" BASIS,
12*0a450197SShawn McCarney  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13*0a450197SShawn McCarney  * See the License for the specific language governing permissions and
14*0a450197SShawn McCarney  * limitations under the License.
15*0a450197SShawn McCarney  */
16*0a450197SShawn McCarney #include "sensors.hpp"
17*0a450197SShawn McCarney 
18*0a450197SShawn McCarney #include <gtest/gtest.h>
19*0a450197SShawn McCarney 
20*0a450197SShawn McCarney using namespace phosphor::power::regulators;
21*0a450197SShawn McCarney using namespace phosphor::power::regulators::sensors;
22*0a450197SShawn McCarney 
TEST(SensorsTests,ToString)23*0a450197SShawn McCarney TEST(SensorsTests, ToString)
24*0a450197SShawn McCarney {
25*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::iout), "iout");
26*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::iout_peak), "iout_peak");
27*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::iout_valley), "iout_valley");
28*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::pout), "pout");
29*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::temperature), "temperature");
30*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::temperature_peak), "temperature_peak");
31*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::vout), "vout");
32*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::vout_peak), "vout_peak");
33*0a450197SShawn McCarney     EXPECT_EQ(toString(SensorType::vout_valley), "vout_valley");
34*0a450197SShawn McCarney }
35