提交 ff4d6021 编写于 作者: C chengxingzhen

xts-testsuite重复命名修改

Signed-off-by: Nchengxingzhen <chengxingzhen@huawei.com>
上级 5cbd7cdc
...@@ -17,5 +17,5 @@ import Test from './Test' ...@@ -17,5 +17,5 @@ import Test from './Test'
export default function List() { export default function List() {
LifeCycleTest() LifeCycleTest()
// Test(context) Test(globalThis.abilityContext)
} }
\ No newline at end of file
...@@ -15,16 +15,16 @@ ...@@ -15,16 +15,16 @@
import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from "@ohos/hypium" import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from "@ohos/hypium"
export default function lifecycleTest(abilityContext) { export default function lifecycleTest(abilityContext) {
describe('LifeCycleTest', function () { describe('LifeCycleOneTest', function () {
beforeEach(async function (done) { beforeEach(async function (done) {
console.info('LifeCycleTest before each called'); console.info('LifeCycleOneTest before each called');
await sleep(1000); await sleep(1000);
done() done()
}); });
afterEach(async function (done) { afterEach(async function (done) {
console.info('LifeCycleTest after each called'); console.info('LifeCycleOneTest after each called');
if ("Singlehap_LifeCycleTest_0200" === TAG || "Singlehap_LifeCycleTest_0300" === TAG if ("Singlehap_LifeCycleTest_0200" === TAG || "Singlehap_LifeCycleTest_0300" === TAG
|| "Singlehap_LifeCycleTest_0500" === TAG || "Singlehap_LifeCycleTest_0600" === TAG || "Singlehap_LifeCycleTest_0500" === TAG || "Singlehap_LifeCycleTest_0600" === TAG
|| "Singlehap_LifeCycleTest_0800" === TAG || "Singlehap_LifeCycleTest_0900" === TAG) { || "Singlehap_LifeCycleTest_0800" === TAG || "Singlehap_LifeCycleTest_0900" === TAG) {
...@@ -35,12 +35,12 @@ export default function lifecycleTest(abilityContext) { ...@@ -35,12 +35,12 @@ export default function lifecycleTest(abilityContext) {
"bundleName": "com.example.lifecycle_xts" "bundleName": "com.example.lifecycle_xts"
} }
} }
console.log("LifeCycleTest terminateSelfwithresult para: " + JSON.stringify(para)); console.log("LifeCycleOneTest terminateSelfwithresult para: " + JSON.stringify(para));
await globalThis.ability1context.terminateSelfWithResult(para) await globalThis.ability1context.terminateSelfWithResult(para)
.then((data) => { .then((data) => {
console.log("LifeCycleTest terminateSelfwithresult successful data: " + JSON.stringify(data)); console.log("LifeCycleOneTest terminateSelfwithresult successful data: " + JSON.stringify(data));
}).catch((error) => { }).catch((error) => {
console.log("LifeCycleTest terminateSelfwithresult error: " + JSON.stringify(error)); console.log("LifeCycleOneTest terminateSelfwithresult error: " + JSON.stringify(error));
}); });
} else if ("Singlehap_LifeCycleTest_2000" === TAG) { } else if ("Singlehap_LifeCycleTest_2000" === TAG) {
var para1 = { var para1 = {
...@@ -50,12 +50,12 @@ export default function lifecycleTest(abilityContext) { ...@@ -50,12 +50,12 @@ export default function lifecycleTest(abilityContext) {
"bundleName": "com.example.lifecycle_xts" "bundleName": "com.example.lifecycle_xts"
} }
} }
console.log("LifeCycleTest terminateSelfwithresult para: " + JSON.stringify(para1)); console.log("LifeCycleOneTest terminateSelfwithresult para: " + JSON.stringify(para1));
await globalThis.ability12.terminateSelfWithResult(para1) await globalThis.ability12.terminateSelfWithResult(para1)
.then((data) => { .then((data) => {
console.log("LifeCycleTest terminateSelfwithresult successful data: " + JSON.stringify(data)); console.log("LifeCycleOneTest terminateSelfwithresult successful data: " + JSON.stringify(data));
}).catch((error) => { }).catch((error) => {
console.log("LifeCycleTest terminateSelfwithresult error: " + JSON.stringify(error)); console.log("LifeCycleOneTest terminateSelfwithresult error: " + JSON.stringify(error));
}); });
} }
done(); done();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册