提交 8459ece0 编写于 作者: C chenxuihui

hisysevent xts suites bugfix

Signed-off-by: Nchenxuihui <chenxuhui2@huawei.com>
上级 ec2e2e09
...@@ -22,10 +22,10 @@ group("hiviewdfxtestacts") { ...@@ -22,10 +22,10 @@ group("hiviewdfxtestacts") {
"hidebugtest/hidebugtestjstest:ActsHiDebugTest", "hidebugtest/hidebugtestjstest:ActsHiDebugTest",
"hilogtest/hilogjstest:ActsHilogJsTest", "hilogtest/hilogjstest:ActsHilogJsTest",
"hilogtest/hilogndktest:hilogndktest", "hilogtest/hilogndktest:hilogndktest",
"hisyseventtest/hisyseventjstest:ActsHiSysEventJsTest",
"hitracechainjstest:ActsHiTraceChainJsTest", "hitracechainjstest:ActsHiTraceChainJsTest",
"hitracechaintest:ActsHiTraceChainTest", "hitracechaintest:ActsHiTraceChainTest",
"hiview/faultlogger/faultloggerjs:faultloggerjs_test", "hiview/faultlogger/faultloggerjs:faultloggerjs_test",
"hisyseventtest/hisyseventjstest:ActsHiSysEventJsTest",
] ]
} }
} }
...@@ -17,36 +17,21 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from ' ...@@ -17,36 +17,21 @@ import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from '
describe('hiSysEventJsTest', function () { describe('hiSysEventJsTest', function () {
beforeAll(function() { beforeAll(function() {
/**
* @tc.setup: setup invoked before all test cases
*/
console.info('hiSysEventJsTest beforeAll called') console.info('hiSysEventJsTest beforeAll called')
}) })
afterAll(function() { afterAll(function() {
/**
* @tc.teardown: teardown invoked after all test cases
*/
console.info('hiSysEventJsTest afterAll called') console.info('hiSysEventJsTest afterAll called')
}) })
beforeEach(function() { beforeEach(function() {
/**
* @tc.setup: setup invoked before each test case
*/
console.info('hiSysEventJsTest beforeEach called') console.info('hiSysEventJsTest beforeEach called')
}) })
afterEach(function() { afterEach(function() {
/**
* @tc.teardown: teardown invoked after each test case
*/
console.info('hiSysEventJsTest afterEach called') console.info('hiSysEventJsTest afterEach called')
}) })
/** /**
* @tc.number DFX_DFT_HiSysEvent_JS_0100 * @tc.number DFX_DFT_HiSysEvent_JS_0100
* @tc.name testHiSysEventApi01 * @tc.name testHiSysEventApi01
...@@ -93,6 +78,7 @@ describe('hiSysEventJsTest', function () { ...@@ -93,6 +78,7 @@ describe('hiSysEventJsTest', function () {
) )
console.info('testHiSysEventApi02 end') console.info('testHiSysEventApi02 end')
}) })
/** /**
* @tc.number DFX_DFT_HiSysEvent_JS_0400 * @tc.number DFX_DFT_HiSysEvent_JS_0400
* @tc.name testHiSysEventApi04 * @tc.name testHiSysEventApi04
...@@ -345,7 +331,8 @@ describe('hiSysEventJsTest', function () { ...@@ -345,7 +331,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi12: OnEvent...`) console.info(`testHiSysEventApi12: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi12: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi12: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi12: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi12: ${key}: ${info.params[key]}`)
...@@ -378,7 +365,8 @@ describe('hiSysEventJsTest', function () { ...@@ -378,7 +365,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi13: OnEvent...`) console.info(`testHiSysEventApi13: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi13: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi13: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi13: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi13: ${key}: ${info.params[key]}`)
...@@ -411,7 +399,8 @@ describe('hiSysEventJsTest', function () { ...@@ -411,7 +399,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi14: OnEvent...`) console.info(`testHiSysEventApi14: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi14: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi14: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi14: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi14: ${key}: ${info.params[key]}`)
...@@ -445,7 +434,8 @@ describe('hiSysEventJsTest', function () { ...@@ -445,7 +434,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi15: OnEvent...`) console.info(`testHiSysEventApi15: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi15: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi15: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi15: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi15: ${key}: ${info.params[key]}`)
...@@ -479,7 +469,8 @@ describe('hiSysEventJsTest', function () { ...@@ -479,7 +469,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi16: OnEvent...`) console.info(`testHiSysEventApi16: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi16: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi16: domain is : ${info.domain},
name is ${info.name}, eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi16: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi16: ${key}: ${info.params[key]}`)
...@@ -513,7 +504,8 @@ describe('hiSysEventJsTest', function () { ...@@ -513,7 +504,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi17: OnEvent...`) console.info(`testHiSysEventApi17: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi17: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi17: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi17: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi17: ${key}: ${info.params[key]}`)
...@@ -546,7 +538,8 @@ describe('hiSysEventJsTest', function () { ...@@ -546,7 +538,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi18: OnEvent...`) console.info(`testHiSysEventApi18: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi18: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi18: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi18: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi18: ${key}: ${info.params[key]}`)
...@@ -584,7 +577,8 @@ describe('hiSysEventJsTest', function () { ...@@ -584,7 +577,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi19: OnEvent...`) console.info(`testHiSysEventApi19: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi19: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi19: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi19: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi19: ${key}: ${info.params[key]}`)
...@@ -622,7 +616,8 @@ describe('hiSysEventJsTest', function () { ...@@ -622,7 +616,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi20: OnEvent...`) console.info(`testHiSysEventApi20: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi20: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi20: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi20: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi20: ${key}: ${info.params[key]}`)
...@@ -661,7 +656,8 @@ describe('hiSysEventJsTest', function () { ...@@ -661,7 +656,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi21: OnEvent...`) console.info(`testHiSysEventApi21: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi21: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi21: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi21: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi21: ${key}: ${info.params[key]}`)
...@@ -700,7 +696,8 @@ describe('hiSysEventJsTest', function () { ...@@ -700,7 +696,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi22: OnEvent...`) console.info(`testHiSysEventApi22: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi22: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi22: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi22: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi22: ${key}: ${info.params[key]}`)
...@@ -739,7 +736,8 @@ describe('hiSysEventJsTest', function () { ...@@ -739,7 +736,8 @@ describe('hiSysEventJsTest', function () {
onEvent: (info) => { onEvent: (info) => {
console.info(`testHiSysEventApi23: OnEvent...`) console.info(`testHiSysEventApi23: OnEvent...`)
expect(Object.keys(info).length > 0).assertTrue() expect(Object.keys(info).length > 0).assertTrue()
console.info(`testHiSysEventApi23: domain is : ${info.domain}, name is ${info.name}, eventType is ${info.eventType}`) console.info(`testHiSysEventApi23: domain is : ${info.domain}, name is ${info.name},
eventType is ${info.eventType}`)
if (info.params instanceof Object) { if (info.params instanceof Object) {
for (const key in info.params) { for (const key in info.params) {
console.info(`testHiSysEventApi23: ${key}: ${info.params[key]}`) console.info(`testHiSysEventApi23: ${key}: ${info.params[key]}`)
...@@ -806,7 +804,8 @@ describe('hiSysEventJsTest', function () { ...@@ -806,7 +804,8 @@ describe('hiSysEventJsTest', function () {
if (infos instanceof Array) { if (infos instanceof Array) {
for (let i = 0; i < infos.length; i++) { for (let i = 0; i < infos.length; i++) {
let item = infos[i]; let item = infos[i];
console.info(`testHiSysEventApi24: domain is ${item.domain}, name is ${item.name}, eventType is ${item.eventType}`) console.info(`testHiSysEventApi24: domain is ${item.domain}, name is ${item.name},
eventType is ${item.eventType}`)
if (item.params instanceof Object) { if (item.params instanceof Object) {
for (const key in item.params) { for (const key in item.params) {
console.info(`testHiSysEventApi24: ${key}: ${item.params[key]}`) console.info(`testHiSysEventApi24: ${key}: ${item.params[key]}`)
...@@ -884,7 +883,8 @@ describe('hiSysEventJsTest', function () { ...@@ -884,7 +883,8 @@ describe('hiSysEventJsTest', function () {
if (infos instanceof Array) { if (infos instanceof Array) {
for (let i = 0; i < infos.length; i++) { for (let i = 0; i < infos.length; i++) {
let item = infos[i]; let item = infos[i];
console.info(`testHiSysEventApi25: domain is ${item.domain}, name is ${item.name}, eventType is ${item.eventType}`) console.info(`testHiSysEventApi25: domain is ${item.domain}, name is ${item.name},
eventType is ${item.eventType}`)
if (item.params instanceof Object) { if (item.params instanceof Object) {
for (const key in item.params) { for (const key in item.params) {
console.info(`testHiSysEventApi25: ${key}: ${item.params[key]}`) console.info(`testHiSysEventApi25: ${key}: ${item.params[key]}`)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册