From e6575c3d322422d324439d01227ee6787f26253e Mon Sep 17 00:00:00 2001 From: zhangyushuai Date: Wed, 13 Jul 2022 06:52:28 +0000 Subject: [PATCH] fixed d75981f from https://gitee.com/yu-shuai-zhang/xts_acts/pulls/4288 add pastboard promise appi and formate build.gn 3 Signed-off-by: zhangyushuai --- miscservices/BUILD.gn | 1 + .../src/main/js/default/test/PasteBoardJsunit.test.js | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/miscservices/BUILD.gn b/miscservices/BUILD.gn index 073e36c5a..0e05ce9de 100755 --- a/miscservices/BUILD.gn +++ b/miscservices/BUILD.gn @@ -20,6 +20,7 @@ group("miscservices") { "TimeTest_js:ActsTimeJSApiTest", "TimerTest_js:ActsTimerJSApiTest", "actspasteboardjsapitest:ActsPasteBoardJSApiTest", + "screenlock_js:ActsScreenLockJSApiTest", "wallpaper_js:ActsWallpaperJSApiTest", ] } diff --git a/miscservices/actspasteboardjsapitest/entry/src/main/js/default/test/PasteBoardJsunit.test.js b/miscservices/actspasteboardjsapitest/entry/src/main/js/default/test/PasteBoardJsunit.test.js index 59c290c2d..8386280a1 100644 --- a/miscservices/actspasteboardjsapitest/entry/src/main/js/default/test/PasteBoardJsunit.test.js +++ b/miscservices/actspasteboardjsapitest/entry/src/main/js/default/test/PasteBoardJsunit.test.js @@ -3629,7 +3629,12 @@ describe('PasteBoardTest', function() { console.log('f_test69 Converts the PlainTextData to text') var pasteDataRecord = pasteData1.getRecordAt(0) - console.log('f_test69 pasteDataRecord.convertToText = ' + pasteDataRecord.convertToText); + + pasteDataRecord.convertToText().then((data) => { + console.info('convertToText success data : ' + JSON.stringify(data)); + }).catch((error) => { + console.error('convertToText failed because ' + JSON.stringify(error)); + });; console.log('SUB_pasteBoard_function_JS_API_6900 end'); done(); -- GitLab