1 /* 2 * Copyright (c) 2022 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 "token_sync_kit_test.h" 17 18 #include "i_token_sync_manager.h" 19 #include "token_sync_manager_client.h" 20 21 using namespace testing::ext; 22 23 namespace OHOS { 24 namespace Security { 25 namespace AccessToken { SetUpTestCase()26void TokenSyncKitTest::SetUpTestCase() 27 {} 28 TearDownTestCase()29void TokenSyncKitTest::TearDownTestCase() 30 { 31 } 32 SetUp()33void TokenSyncKitTest::SetUp() 34 { 35 } 36 TearDown()37void TokenSyncKitTest::TearDown() 38 {} 39 40 /** 41 * @tc.name: UpdateRemoteHapTokenInfo001 42 * @tc.desc: TokenSyncManagerProxy::UpdateRemoteHapTokenInfo function test 43 * @tc.type: FUNC 44 * @tc.require: 45 */ 46 HWTEST_F(TokenSyncKitTest, UpdateRemoteHapTokenInfo001, TestSize.Level1) 47 { 48 HapTokenInfoForSync tokenInfo; 49 50 ASSERT_EQ(TokenSyncError::TOKEN_SYNC_IPC_ERROR, 51 TokenSyncManagerClient::GetInstance().UpdateRemoteHapTokenInfo(tokenInfo)); 52 } 53 } // namespace AccessToken 54 } // namespace Security 55 } // namespace OHOS 56