• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2021 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #include <gtest/gtest.h>
17 #include "device/device_manager_agent.h"
18 
19 namespace OHOS {
20 namespace Storage {
21 namespace DistributedFile {
22 namespace Test {
23 using namespace testing::ext;
24 
25 class DeviceManagerAgentTest : public testing::Test {
26 public:
27     static void SetUpTestCase(void);
28     static void TearDownTestCase(void);
29     void SetUp();
30     void TearDown();
31 };
32 
SetUpTestCase(void)33 void DeviceManagerAgentTest::SetUpTestCase(void)
34 {
35     // input testsuit setup step,setup invoked before all testcases
36 }
37 
TearDownTestCase(void)38 void DeviceManagerAgentTest::TearDownTestCase(void)
39 {
40     // input testsuit teardown step,teardown invoked after all testcases
41 }
42 
SetUp(void)43 void DeviceManagerAgentTest::SetUp(void)
44 {
45     // input testcase setup step,setup invoked before each testcases
46 }
47 
TearDown(void)48 void DeviceManagerAgentTest::TearDown(void)
49 {
50     // input testcase teardown step,teardown invoked after each testcases
51 }
52 
53 /**
54  * @tc.name: integer_sub_001
55  * @tc.desc: Verify the sub function.
56  * @tc.type: FUNC
57  * @tc.require: Issue Number
58  */
59 HWTEST_F(DeviceManagerAgentTest, test_001, TestSize.Level1)
60 {
61     // step 1:调用函数获取结果
62     int actual = 4;
63     // Step 2:使用断言比较预期与实际结果
64     EXPECT_EQ(4, actual);
65 }
66 } // namespace Test
67 } // namespace DistributedFile
68 } // namespace Storage
69 } // namespace OHOS