提交 ac21e147 编写于 作者: H huyunhui1

Merge branch 'master' of gitee.com:huyunhui1/xts_acts

Signed-off-by: Nhuyunhui1 <huyunhui1@huawei.com>
...@@ -18,7 +18,7 @@ group("esmodule") { ...@@ -18,7 +18,7 @@ group("esmodule") {
if (is_standard_system) { if (is_standard_system) {
deps = [ deps = [
"esmodule_entry:ActsEsmoduleEntryTest", "esmodule_entry:ActsEsmoduleEntryTest",
"esmodule_ohostest:ActsEsmoduleOhostestTest" "esmodule_ohostest:ActsEsmoduleOhostestTest",
] ]
} }
} }
...@@ -18,5 +18,6 @@ ohos_js_app_suite("ActsEsmoduleEntryTest") { ...@@ -18,5 +18,6 @@ ohos_js_app_suite("ActsEsmoduleEntryTest") {
testonly = true testonly = true
part_name = "ets_frontend" part_name = "ets_frontend"
subsystem_name = "arkcompiler" subsystem_name = "arkcompiler"
certificate_profile = "./signature/auto_ohos_default_esmodule_entry_com.esmodule.acts.p7b" certificate_profile =
"./signature/auto_ohos_default_esmodule_entry_com.esmodule.acts.p7b"
} }
...@@ -18,9 +18,9 @@ import worker from '@ohos.worker'; ...@@ -18,9 +18,9 @@ import worker from '@ohos.worker';
const ADDEND_FIRST = 2; const ADDEND_FIRST = 2;
const ADDEND_SECOND = 3; const ADDEND_SECOND = 3;
const SUM = 5; const SUM = 5;
var workerPort = worker.workerPort; let workerPort = worker.workerPort;
workerPort.onmessage = function(): void { workerPort.onmessage = function(): void {
if (add(ADDEND_FIRST, ADD_SECOND) === SUM) { if (add(ADDEND_FIRST, ADDEND_SECOND) === SUM) {
workerPort.postMessage('ModuleTest receive data from main thread'); workerPort.postMessage('ModuleTest receive data from main thread');
} }
}; };
\ No newline at end of file
...@@ -20,7 +20,7 @@ const ADDEND_SECOND = 3; ...@@ -20,7 +20,7 @@ const ADDEND_SECOND = 3;
const SUM = 5; const SUM = 5;
let workerPort = worker.workerPort; let workerPort = worker.workerPort;
workerPort.onmessage = function(): void { workerPort.onmessage = function(): void {
if (add(ADDEND_FIRST, ADD_SECOND) === SUM) { if (add(ADDEND_FIRST, ADDEND_SECOND) === SUM) {
workerPort.postMessage('ModuleTest receive data from main thread'); workerPort.postMessage('ModuleTest receive data from main thread');
} }
}; };
\ No newline at end of file
...@@ -19,5 +19,6 @@ ohos_js_app_suite("ActsEsmoduleOhostestTest") { ...@@ -19,5 +19,6 @@ ohos_js_app_suite("ActsEsmoduleOhostestTest") {
testonly = true testonly = true
part_name = "ets_frontend" part_name = "ets_frontend"
subsystem_name = "arkcompiler" subsystem_name = "arkcompiler"
certificate_profile = "./signature/auto_ohos_default_esmodule_ohosTest_com.esmodule.acts.p7b" certificate_profile =
"./signature/auto_ohos_default_esmodule_ohosTest_com.esmodule.acts.p7b"
} }
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册