From d55105b57b6abadec85fe1ea58dfd1d0c81e2f40 Mon Sep 17 00:00:00 2001 From: HuangXW Date: Thu, 5 Jan 2023 01:44:46 +0000 Subject: [PATCH] remove createBundleContext testcase Change-Id: Id01aaeb6df15ec22d3647e4879e6103da7556b91 Signed-off-by: HuangXW --- .../main/ets/test/StageAppContext.test.ets | 38 ------------------- 1 file changed, 38 deletions(-) diff --git a/ability/ability_runtime/context/actsstageappcontext/actsstageappcontexttest/entry/src/main/ets/test/StageAppContext.test.ets b/ability/ability_runtime/context/actsstageappcontext/actsstageappcontexttest/entry/src/main/ets/test/StageAppContext.test.ets index 9799bd91f..f449067dd 100644 --- a/ability/ability_runtime/context/actsstageappcontext/actsstageappcontexttest/entry/src/main/ets/test/StageAppContext.test.ets +++ b/ability/ability_runtime/context/actsstageappcontext/actsstageappcontexttest/entry/src/main/ets/test/StageAppContext.test.ets @@ -39,25 +39,6 @@ export default function stageAppContextTest(abilityContext) { }, 1000); }) - /** - * @tc.number: SUB_AA_OpenHarmony_ApplicationContext_0100 - * @tc.name: Validating the context obtained by the AbilityContext call - * getApplicationContext can be obtained using createBundleContext - * @tc.desc: Function test - * @tc.level 0 - */ - it('SUB_AA_OpenHarmony_ApplicationContext_0100', 0, async function (done) { - let TAG = "SUB_AA_OpenHarmony_ApplicationContext_0100"; - console.log(TAG + " --- start"); - let context = abilityContext.getApplicationContext(); - let result = context.createBundleContext('com.example.stageappcontexttest') - let getCacheDir = result.cacheDir - console.log(TAG + 'getCacheDir::' + JSON.stringify(getCacheDir)); - expect(getCacheDir).assertEqual('/data/app/el2/100/base/com.example.stageappcontexttest/cache') - done(); - }); - - /** * @tc.number: SUB_AA_OpenHarmony_ApplicationContext_0200 * @tc.name: Validating the context obtained by the AbilityContext call @@ -146,25 +127,6 @@ export default function stageAppContextTest(abilityContext) { done(); }); - /** - * @tc.number: SUB_AA_OpenHarmony_ApplicationContext_1100 - * @tc.name: Verify that the application-level context call interface - * getApplicationContext gets the context using createBundleContext - * @tc.desc: Function test - * @tc.level 3 - */ - it('SUB_AA_OpenHarmony_ApplicationContext_1100', 0, async function (done) { - let TAG = "SUB_AA_OpenHarmony_ApplicationContext_1100"; - console.log(TAG + " --- start"); - let context = abilityContext.getApplicationContext(); - let context2 = context.getApplicationContext(); - let result = context2.createBundleContext("com.example.stageappcontexttest"); - let dir = result.cacheDir; - console.log(TAG + " dir = " + dir); - expect(dir).assertEqual("/data/app/el2/100/base/com.example.stageappcontexttest/cache"); - done(); - }); - /** * @tc.number: SUB_AA_OpenHarmony_ApplicationContext_1200 * @tc.name: Verify that the app-level context calls the interface -- GitLab