1f6603c60Sopenharmony_ci/* 2f6603c60Sopenharmony_ci * Copyright (c) 2020-2021 Huawei Device Co., Ltd. 3f6603c60Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License"); 4f6603c60Sopenharmony_ci * you may not use this file except in compliance with the License. 5f6603c60Sopenharmony_ci * You may obtain a copy of the License at 6f6603c60Sopenharmony_ci * 7f6603c60Sopenharmony_ci * http://www.apache.org/licenses/LICENSE-2.0 8f6603c60Sopenharmony_ci * 9f6603c60Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software 10f6603c60Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS, 11f6603c60Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12f6603c60Sopenharmony_ci * See the License for the specific language governing permissions and 13f6603c60Sopenharmony_ci * limitations under the License. 14f6603c60Sopenharmony_ci */ 15f6603c60Sopenharmony_ci 16f6603c60Sopenharmony_ci#include "hctest.h" 17f6603c60Sopenharmony_ci 18f6603c60Sopenharmony_ci/** 19f6603c60Sopenharmony_ci * @tc.name: register a test suit named "IntTestSuite" 20f6603c60Sopenharmony_ci * @param: test subsystem name 21f6603c60Sopenharmony_ci * @param: example module name 22f6603c60Sopenharmony_ci * @param: IntTestSuite test suit name 23f6603c60Sopenharmony_ci */ 24f6603c60Sopenharmony_ciLITE_TEST_SUIT(test, example, IntTestSuite); 25f6603c60Sopenharmony_ci 26f6603c60Sopenharmony_ci/** 27f6603c60Sopenharmony_ci * @tc.setup: define a setup for test suit, format:"IntTestSuite + SetUp" 28f6603c60Sopenharmony_ci * @return: true setup success 29f6603c60Sopenharmony_ci */ 30f6603c60Sopenharmony_cistatic BOOL IntTestSuiteSetUp() 31f6603c60Sopenharmony_ci{ 32f6603c60Sopenharmony_ci LiteTestPrint("test_demo1 setup\n"); 33f6603c60Sopenharmony_ci return TRUE; 34f6603c60Sopenharmony_ci} 35f6603c60Sopenharmony_ci 36f6603c60Sopenharmony_ci/** 37f6603c60Sopenharmony_ci * @tc.teardown: define a setup for test suit, format:"IntTestSuite + TearDown" 38f6603c60Sopenharmony_ci * @return: true teardown success 39f6603c60Sopenharmony_ci */ 40f6603c60Sopenharmony_cistatic BOOL IntTestSuiteTearDown() 41f6603c60Sopenharmony_ci{ 42f6603c60Sopenharmony_ci LiteTestPrint("test_demo1 tearDown\n"); 43f6603c60Sopenharmony_ci return TRUE; 44f6603c60Sopenharmony_ci} 45f6603c60Sopenharmony_ci 46f6603c60Sopenharmony_ci/** 47f6603c60Sopenharmony_ci * @tc.number : Test_Case_100 48f6603c60Sopenharmony_ci * @tc.name : Verify int check function 49f6603c60Sopenharmony_ci * @tc.desc : [C- SOFTWARE -0200] 50f6603c60Sopenharmony_ci */ 51f6603c60Sopenharmony_ciLITE_TEST_CASE(IntTestSuite, TestCase001, Function | MediumTest | Level1) 52f6603c60Sopenharmony_ci{ 53f6603c60Sopenharmony_ci TEST_ASSERT_EQUAL_INT(LEVEL2, LEVEL3); 54f6603c60Sopenharmony_ci}; 55f6603c60Sopenharmony_ci 56f6603c60Sopenharmony_ci/** 57f6603c60Sopenharmony_ci * @tc.number : Test_Case_200 58f6603c60Sopenharmony_ci * @tc.name : Verify int check function 59f6603c60Sopenharmony_ci * @tc.desc : [C- SOFTWARE -0200] 60f6603c60Sopenharmony_ci */ 61f6603c60Sopenharmony_ciLITE_TEST_CASE(IntTestSuite, TestCase002, Function | MediumTest | Level2) 62f6603c60Sopenharmony_ci{ 63f6603c60Sopenharmony_ci TEST_ASSERT_EQUAL_INT(LEVEL2, LEVEL2); 64f6603c60Sopenharmony_ci}; 65f6603c60Sopenharmony_ci 66f6603c60Sopenharmony_ciRUN_TEST_SUITE(IntTestSuite);