提交 cc7aa374 编写于 作者: Y y00314596

add api cases by yangqing3@huawei.com

Signed-off-by: Ny00314596 <yangqing3@huawei.com>
上级 72a08029
......@@ -1056,6 +1056,19 @@ describe('intlTest', function () {
expect(numfmt.format(123456.789)).assertEqual('+¥123,457');
})
/* *
* @tc.number SUB_GLOBAL_INTL_JS_NUMBER_2250
* @tc.name format the number with unitUsage
* @tc.desc check the number with unitUsage
*/
it('formatNumber_test_2250', 0, function () {
let numfmt = new intl.NumberFormat('zh-CN', { style: 'unit', unit: 'meter',
unitDisplay: 'long', unitUsage: 'length-road' });
console.log('formatNumber_test_2250 ' + numfmt.format(123456.789));
expect(numfmt.format(123456.789)).assertEqual('123,456.789米');
expect(numfmt.resolvedOptions().unitUsage).assertEqual('length-road');
})
/* *
* @tc.number SUB_GLOBAL_INTL_JS_NUMBER_2100
* @tc.name format the number with signDisplay
......
......@@ -242,6 +242,7 @@ describe('resMgrTest', function () {
dc.screenDensity = ScreenDensity.SCREEN_XXLDPI;
dc.deviceType = DeviceType.DEVICE_TYPE_WEARABLE;
dc.screenDensity = ScreenDensity.SCREEN_XXXLDPI;
dc.deviceType = DeviceType.DEVICE_TYPE_PC;
expect(dc !== null).assertTrue();
console.log('getDeviceCapability_test_002 ' + dc);
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册