From 6f08e93dc851b38f446d52fbed7e77f1906f8809 Mon Sep 17 00:00:00 2001 From: y00314596 Date: Tue, 8 Feb 2022 15:32:37 +0800 Subject: [PATCH] add by yangqing3@huawei.com Signed-off-by: y00314596 --- .../src/main/js/default/test/Lang.test.js | 48 +++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/global/i18n_standard/intljs/src/main/js/default/test/Lang.test.js b/global/i18n_standard/intljs/src/main/js/default/test/Lang.test.js index 9be84d0da..6efb3800e 100755 --- a/global/i18n_standard/intljs/src/main/js/default/test/Lang.test.js +++ b/global/i18n_standard/intljs/src/main/js/default/test/Lang.test.js @@ -434,5 +434,53 @@ describe('LangTest', function () { expect(list.length).assertLarger(0); }) + /* * + * @tc.number SUB_GLOBAL_INTL_JS_TRANSFER_0100 + * @tc.name transfer from lower to upper + * @tc.desc check the transfer result + */ + it('transfer_test_0100', 0, function () { + let date = 'hello'; + let value = date.toLocaleUpperCase('zh-CN'); + console.log('transfer_test_0100 ' + value); + expect(value).assertEqual('HELLO'); + }) + + /* * + * @tc.number SUB_GLOBAL_INTL_JS_TRANSFER_0200 + * @tc.name transfer from upper to lower + * @tc.desc check the transfer result + */ + it('transfer_test_0200', 0, function () { + let date = 'WORLD'; + let value = date.toLocaleLowerCase('zh-CN'); + console.log('transfer_test_0200 ' + value); + expect(value).assertEqual('world'); + }) + + /* * + * @tc.number SUB_GLOBAL_INTL_JS_TRANSFER_0300 + * @tc.name transfer to upper + * @tc.desc check the transfer result + */ + it('transfer_test_0300', 0, function () { + let date = 'My name is Jack.'; + let value = date.toLocaleUpperCase('en-US'); + console.log('transfer_test_0300 ' + value); + expect(value).assertEqual('MY NAME IS JACK.'); + }) + + /* * + * @tc.number SUB_GLOBAL_INTL_JS_TRANSFER_0400 + * @tc.name transfer to lower + * @tc.desc check the transfer result + */ + it('transfer_test_0400', 0, function () { + let date = 'The sky is in BLUE-STYLE!'; + let value = date.toLocaleLowerCase('en-US'); + console.log('transfer_test_0400 ' + value); + expect(value).assertEqual('the sky is in blue-style!'); + }) + console.log('*************end LangTest*************'); }) \ No newline at end of file -- GitLab