提交 dc12624e 编写于 作者: B bayanxing

ace_ets_component部分用例未走回调便判断pass问题修复

Signed-off-by: Nbayanxing <bayanxing@kaihong.com>
上级 e84cc522
...@@ -22,7 +22,7 @@ import prompt from '@system.prompt' ...@@ -22,7 +22,7 @@ import prompt from '@system.prompt'
@Component @Component
struct AppearExample { struct AppearExample {
@State isShow: boolean = true @State isShow: boolean = true
@State appearFlag: boolean = false @State appearFlag: string = "appearStatusOff"
@State disAppearFlag: boolean = false @State disAppearFlag: boolean = false
private changeAppear: string = 'Hide Text' private changeAppear: string = 'Hide Text'
private myText: string = 'Text for onAppear' private myText: string = 'Text for onAppear'
...@@ -52,26 +52,41 @@ struct AppearExample { ...@@ -52,26 +52,41 @@ struct AppearExample {
.key('appear') .key('appear')
.onClick(() => { .onClick(() => {
this.isShow = !this.isShow this.isShow = !this.isShow
try {
var backData = {
data: {
"ACTION": this.isShow,
}
}
var backEvent = {
eventId: 58,
priority: events_emitter.EventPriority.LOW
}
console.info("appearFlag start to emit action state")
events_emitter.emit(backEvent, backData)
} catch {
console.info("appearFlag emit action state err: " + JSON.stringify(err.message))
}
}).margin(3).backgroundColor(0x2788D9) }).margin(3).backgroundColor(0x2788D9)
if (this.isShow) { if (this.isShow) {
Text(this.myText) Text(this.myText)
.onAppear(() => { .onAppear(() => {
this.appearFlag = true this.appearFlag = "appearStatusOn"
this.changeAppear = 'Show Text' this.changeAppear = 'Show Text'
console.info('appearFlag current action state is: ' + this.appearFlag); console.info('appearFlag current action state is: ' + this.appearFlag);
prompt.showToast({ message: 'The text is shown', duration: 2000 }) prompt.showToast({ message: 'The text is shown', duration: 2000 })
try { try {
var backData = { var backData2 = {
data: { data: {
"ACTION": this.appearFlag, "APPEAR": this.appearFlag,
} }
} }
var backEvent = { var backEvent2 = {
eventId: 59, eventId: 59,
priority: events_emitter.EventPriority.LOW priority: events_emitter.EventPriority.LOW
} }
console.info("appearFlag start to emit action state") console.info("appearFlag start to emit action state")
events_emitter.emit(backEvent, backData) events_emitter.emit(backEvent2, backData2)
} catch { } catch {
console.info("appearFlag emit action state err: " + JSON.stringify(err.message)) console.info("appearFlag emit action state err: " + JSON.stringify(err.message))
} }
...@@ -82,17 +97,17 @@ struct AppearExample { ...@@ -82,17 +97,17 @@ struct AppearExample {
console.info('disAppearFlag current action state is: ' + this.disAppearFlag); console.info('disAppearFlag current action state is: ' + this.disAppearFlag);
prompt.showToast({ message: 'The text is hidden', duration: 2000 }) prompt.showToast({ message: 'The text is hidden', duration: 2000 })
try { try {
var backData = { var backData1 = {
data: { data: {
"ACTION": this.disAppearFlag, "ACTION": this.disAppearFlag,
} }
} }
var backEvent = { var backEvent1 = {
eventId: 60, eventId: 60,
priority: events_emitter.EventPriority.LOW priority: events_emitter.EventPriority.LOW
} }
console.info("disAppearFlag start to emit action state") console.info("disAppearFlag start to emit action state")
events_emitter.emit(backEvent, backData) events_emitter.emit(backEvent1, backData1)
} catch { } catch {
console.info("disAppearFlag emit action state err: " + JSON.stringify(err.message)) console.info("disAppearFlag emit action state err: " + JSON.stringify(err.message))
} }
......
...@@ -54,17 +54,17 @@ struct AreaExample { ...@@ -54,17 +54,17 @@ struct AreaExample {
this.onActionCalled = true; this.onActionCalled = true;
console.info('onAreaChange current action state is: ' + this.onActionCalled); console.info('onAreaChange current action state is: ' + this.onActionCalled);
try { try {
var backData = { var backData1 = {
data: { data: {
"ACTION": this.onActionCalled, "ACTION": this.onActionCalled,
} }
} }
var backEvent = { var backEvent1 = {
eventId: 62, eventId: 62,
priority: events_emitter.EventPriority.LOW priority: events_emitter.EventPriority.LOW
} }
console.info("onAreaChange start to emit action state") console.info("onAreaChange start to emit action state")
events_emitter.emit(backEvent, backData) events_emitter.emit(backEvent1, backData1)
} catch (err) { } catch (err) {
console.info("onAreaChange emit action state err: " + JSON.stringify(err.message)) console.info("onAreaChange emit action state err: " + JSON.stringify(err.message))
} }
......
...@@ -210,7 +210,7 @@ struct SwiperExample { ...@@ -210,7 +210,7 @@ struct SwiperExample {
this.loop = eventData.data.loop; this.loop = eventData.data.loop;
} }
if (eventData.data.duration != null) { if (eventData.data.duration != null) {
this.duration = parseInt(eventData.data.duration); this.duration = eventData.data.duration;
} }
if (eventData.data.vertical != null) { if (eventData.data.vertical != null) {
this.vertical = eventData.data.vertical; this.vertical = eventData.data.vertical;
......
...@@ -22,25 +22,6 @@ import events_emitter from '@ohos.events.emitter'; ...@@ -22,25 +22,6 @@ import events_emitter from '@ohos.events.emitter';
struct TouchAbleExample { struct TouchAbleExample {
@State text1: string = ''; @State text1: string = '';
@State text2: string = ''; @State text2: string = '';
@State touchableValue: boolean = false;
private stateChangCallBack = (eventData) => {
console.info("[TouchAble] page stateChangCallBack");
if (eventData != null) {
console.info("[TouchAble] page state change called:" + JSON.stringify(eventData));
if (eventData.data.touchableValue != null) {
this.touchableValue = eventData.data.touchableValue;
}
}
}
onPageShow() {
console.info('[TouchAble] page show called');
var stateChangeEvent = {
eventId: 44,
priority: events_emitter.EventPriority.LOW
}
events_emitter.on(stateChangeEvent, this.stateChangCallBack);
}
build() { build() {
Stack() { Stack() {
...@@ -52,6 +33,7 @@ struct TouchAbleExample { ...@@ -52,6 +33,7 @@ struct TouchAbleExample {
console.info(this.text1 = 'Rect Clicked') console.info(this.text1 = 'Rect Clicked')
}) })
.overlay(this.text1, { align: Alignment.Bottom, offset: { x: 0, y: 20 } }) .overlay(this.text1, { align: Alignment.Bottom, offset: { x: 0, y: 20 } })
Ellipse() Ellipse()
.fill(Color.Pink) .fill(Color.Pink)
.width(150) .width(150)
......
...@@ -51,45 +51,29 @@ export default function appearJsunit() { ...@@ -51,45 +51,29 @@ export default function appearJsunit() {
console.info('[testAppear01] START'); console.info('[testAppear01] START');
await Utils.sleep(1000); await Utils.sleep(1000);
try { try {
let callBackAppear = (backData) => { let callBackAppear1 = (backData) => {
console.info("testAppear01 get appearEvent result is: " + JSON.stringify(appearEvent)); console.info("testAppear01 get appearEvent result is: " + JSON.stringify(backData));
expect(backData.data.ACTION).assertEqual(true); expect(backData.data.ACTION).assertEqual(false);
done();
} }
var appearEvent = { var appearEvent1 = {
eventId: 58, eventId: 58,
priority: events_emitter.EventPriority.LOW priority: events_emitter.EventPriority.LOW
} }
events_emitter.on(appearEvent, callBackAppear); events_emitter.on(appearEvent1, callBackAppear1);
} catch (err) { } catch (err) {
console.info("testAppear01 on appearEvent err : " + JSON.stringify(err)); console.info("testAppear01 on appearEvent err : " + JSON.stringify(err));
} }
console.info("testAppear01 click result is: " + JSON.stringify(sendEventByKey('appear', 10, ""))); console.info("testAppear01 click result is: " + JSON.stringify(sendEventByKey('appear', 10, "")));
console.info('[testAppear01] END'); console.info('[testAppear01] END');
done();
});
it('testAppear02', 0, async function (done) {
console.info('[testAppear02] START'); console.info('[testAppear02] START');
await Utils.sleep(1000);
try {
let callBackAppear = (backData) => {
console.info("testAppear02 get appearEvent result is: " + JSON.stringify(appearEvent));
expect(backData.data.ACTION).assertEqual(true);
}
var appearEvent = {
eventId: 59,
priority: events_emitter.EventPriority.LOW
}
events_emitter.on(appearEvent, callBackAppear);
} catch (err) {
console.info("testAppear02 on appearEvent err : " + JSON.stringify(err));
}
console.info("testAppear02 appearEvent click result is: " + JSON.stringify(sendEventByKey('appear', 10, "")));
try { try {
let callBackDisAppear = (backData) => { let callBackDisAppear = (backData1) => {
console.info("testAppear02 get disAppearEvent result is: " + JSON.stringify(disAppearEvent)); console.info("testAppear02 get disAppearEvent result is: " + JSON.stringify(backData1));
expect(backData.data.ACTION).assertEqual(true); console.info("testAppear02 get backData1.data.ACTION result is: " + backData1.data.ACTION);
expect(backData1.data.ACTION).assertEqual(true);
done();
} }
var disAppearEvent = { var disAppearEvent = {
eventId: 60, eventId: 60,
...@@ -99,10 +83,25 @@ export default function appearJsunit() { ...@@ -99,10 +83,25 @@ export default function appearJsunit() {
} catch (err) { } catch (err) {
console.info("testAppear02 on disAppearEvent err : " + JSON.stringify(err)); console.info("testAppear02 on disAppearEvent err : " + JSON.stringify(err));
} }
console.info("testAppear02 disAppearEvent click result is: " + JSON.stringify(sendEventByKey('appear', 10, "")));
console.info('[testAppear02] END');
done();
});
await Utils.sleep(1000);
console.info('[testAppear03] START');
let callBackAppear2 = (backData2) => {
console.info("testAppear03 get appearEvent result is: " + JSON.stringify(backData2));
console.info("testAppear03 get backData2.data.APPEAR: " + backData2.data.APPEAR);
expect(backData2.data.APPEAR).assertEqual("appearStatusOn");
done();
}
var appearEvent2 = {
eventId: 59,
priority: events_emitter.EventPriority.LOW
}
try {
console.info("testAppear03 appearEvent click result is: " + JSON.stringify(sendEventByKey('appear', 10, "")));
events_emitter.on(appearEvent2, callBackAppear2);
} catch (err) {
console.info("testAppear03 on appearEvent err : " + JSON.stringify(err));
}
});
}) })
} }
...@@ -48,9 +48,10 @@ export default function areaChangeJsunit() { ...@@ -48,9 +48,10 @@ export default function areaChangeJsunit() {
it('areaChangeTest_0300', 0, async function (done) { it('areaChangeTest_0300', 0, async function (done) {
console.info('areaChangeTest_0300 START'); console.info('areaChangeTest_0300 START');
await Utils.sleep(1000); await Utils.sleep(1000);
let callback = (indexEvent) => { let callback = (backData) => {
console.info("areaChangeTest_0300 get state result is: " + JSON.stringify(indexEvent)); console.info("areaChangeTest_0300 get state result is: " + JSON.stringify(backData));
expect(indexEvent.data.value).assertEqual('TextText'); expect(backData.data.value).assertEqual('TextText');
done();
} }
let indexEvent = { let indexEvent = {
eventId: 61, eventId: 61,
...@@ -61,44 +62,24 @@ export default function areaChangeJsunit() { ...@@ -61,44 +62,24 @@ export default function areaChangeJsunit() {
} catch (err) { } catch (err) {
console.info("areaChangeTest_0300 on events_emitter err : " + JSON.stringify(err)); console.info("areaChangeTest_0300 on events_emitter err : " + JSON.stringify(err));
} }
console.info("areaChangeTest_0300 click result is: " + JSON.stringify(sendEventByKey('text1', 10, "")));
var innerEventOne = {
eventId: 62,
priority: events_emitter.EventPriority.LOW
}
await Utils.sleep(1500);
var callback1 = (eventData) => {
console.info("areaChangeTest_0300 get event state result is: " + JSON.stringify(eventData));
expect(eventData.data.ACTION).assertEqual(true);
}
try {
events_emitter.on(innerEventOne, callback1);
} catch (err) {
console.info("areaChangeTest_0300 on events_emitter err : " + JSON.stringify(err));
}
console.info('areaChangeTest_0300 END');
done();
});
it('areaChangeTest_0400', 0, async function (done) {
console.info('areaChangeTest_0400 START'); console.info('areaChangeTest_0400 START');
await Utils.sleep(1000); await Utils.sleep(1000);
let callback = (indexEvent) => { let callback1 = (eventData) => {
console.info("areaChangeTest_0400 get state result is: " + JSON.stringify(indexEvent)); console.info("areaChangeTest_0400 get state result is: " + JSON.stringify(eventData));
expect(indexEvent.data.value).assertEqual('TextTextText'); expect(eventData.data.ACTION).assertEqual(true);
done();
} }
let indexEvent = { let indexEvent1 = {
eventId: 62, eventId: 62,
priority: events_emitter.EventPriority.LOW priority: events_emitter.EventPriority.LOW
} }
try { try {
events_emitter.on(indexEvent, callback); events_emitter.on(indexEvent1, callback1);
} catch (err) { } catch (err) {
console.info("areaChangeTest_0400 on events_emitter err : " + JSON.stringify(err)); console.info("areaChangeTest_0400 on events_emitter err : " + JSON.stringify(err));
} }
console.info("areaChangeTest_0400 click result is: " + JSON.stringify(sendEventByKey('text1', 10, ""))); console.info("areaChangeTest_0300 click result is: " + JSON.stringify(sendEventByKey('text1', 10, "")));
console.info('areaChangeTest_0400 END');
done();
}); });
}) })
} }
...@@ -52,6 +52,7 @@ export default function marqueeJsunit() { ...@@ -52,6 +52,7 @@ export default function marqueeJsunit() {
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("testMarquee_0100 get state result is: " + JSON.stringify(indexEvent)); console.info("testMarquee_0100 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.start).assertEqual(true); expect(indexEvent.data.start).assertEqual(true);
done();
} }
let indexEvent = { let indexEvent = {
eventId: 130, eventId: 130,
...@@ -67,6 +68,7 @@ export default function marqueeJsunit() { ...@@ -67,6 +68,7 @@ export default function marqueeJsunit() {
var callback1 = (eventData) => { var callback1 = (eventData) => {
console.info("testMarquee_0100 get event state result is: " + JSON.stringify(eventData)); console.info("testMarquee_0100 get event state result is: " + JSON.stringify(eventData));
expect(eventData.data.fontColor).assertEqual(Color.Blue); expect(eventData.data.fontColor).assertEqual(Color.Blue);
done();
} }
var innerEventOne = { var innerEventOne = {
eventId: 127, eventId: 127,
...@@ -78,7 +80,6 @@ export default function marqueeJsunit() { ...@@ -78,7 +80,6 @@ export default function marqueeJsunit() {
console.info("testMarquee_0100 on events_emitter err : " + JSON.stringify(err)); console.info("testMarquee_0100 on events_emitter err : " + JSON.stringify(err));
} }
console.info('testMarquee_0100 END'); console.info('testMarquee_0100 END');
done();
}); });
it('testMarquee_0200', 0, async function (done) { it('testMarquee_0200', 0, async function (done) {
...@@ -87,6 +88,7 @@ export default function marqueeJsunit() { ...@@ -87,6 +88,7 @@ export default function marqueeJsunit() {
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("testMarquee_0200 get state result is: " + JSON.stringify(indexEvent)); console.info("testMarquee_0200 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.start).assertEqual(true); expect(indexEvent.data.start).assertEqual(true);
done();
} }
let indexEvent = { let indexEvent = {
eventId: 130, eventId: 130,
...@@ -102,6 +104,7 @@ export default function marqueeJsunit() { ...@@ -102,6 +104,7 @@ export default function marqueeJsunit() {
var callback1 = (eventData) => { var callback1 = (eventData) => {
console.info("testMarquee_0200 get event state result is: " + JSON.stringify(eventData)); console.info("testMarquee_0200 get event state result is: " + JSON.stringify(eventData));
expect(eventData.data.fontSize).assertEqual(50); expect(eventData.data.fontSize).assertEqual(50);
done();
} }
var innerEventOne = { var innerEventOne = {
eventId: 128, eventId: 128,
...@@ -113,7 +116,6 @@ export default function marqueeJsunit() { ...@@ -113,7 +116,6 @@ export default function marqueeJsunit() {
console.info("testMarquee_0200 on events_emitter err : " + JSON.stringify(err)); console.info("testMarquee_0200 on events_emitter err : " + JSON.stringify(err));
} }
console.info('testMarquee_0200 END'); console.info('testMarquee_0200 END');
done();
}); });
it('testMarquee_0300', 0, async function (done) { it('testMarquee_0300', 0, async function (done) {
...@@ -122,6 +124,7 @@ export default function marqueeJsunit() { ...@@ -122,6 +124,7 @@ export default function marqueeJsunit() {
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("testMarquee_0300 get state result is: " + JSON.stringify(indexEvent)); console.info("testMarquee_0300 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.start).assertEqual(true); expect(indexEvent.data.start).assertEqual(true);
done();
} }
let indexEvent = { let indexEvent = {
eventId: 130, eventId: 130,
...@@ -137,6 +140,7 @@ export default function marqueeJsunit() { ...@@ -137,6 +140,7 @@ export default function marqueeJsunit() {
var callback1 = (eventData) => { var callback1 = (eventData) => {
console.info("testMarquee_0300 get event state result is: " + JSON.stringify(eventData)); console.info("testMarquee_0300 get event state result is: " + JSON.stringify(eventData));
expect(eventData.data.ACTION).assertEqual(true); expect(eventData.data.ACTION).assertEqual(true);
done();
} }
var innerEventOne = { var innerEventOne = {
eventId: 129, eventId: 129,
...@@ -148,7 +152,6 @@ export default function marqueeJsunit() { ...@@ -148,7 +152,6 @@ export default function marqueeJsunit() {
console.info("testMarquee_0300 on events_emitter err : " + JSON.stringify(err)); console.info("testMarquee_0300 on events_emitter err : " + JSON.stringify(err));
} }
console.info('testMarquee_0300 END'); console.info('testMarquee_0300 END');
done();
}); });
}) })
} }
\ No newline at end of file
...@@ -164,6 +164,7 @@ export default function swiperJsunit() { ...@@ -164,6 +164,7 @@ export default function swiperJsunit() {
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("swiperTest_0800 get state result is: " + JSON.stringify(indexEvent)); console.info("swiperTest_0800 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.ACTION).assertEqual(true); expect(indexEvent.data.ACTION).assertEqual(true);
done();
} }
let indexEvent = { let indexEvent = {
eventId: 205, eventId: 205,
...@@ -177,7 +178,6 @@ export default function swiperJsunit() { ...@@ -177,7 +178,6 @@ export default function swiperJsunit() {
console.info("swiperTest_0800 click result is: " + JSON.stringify(sendEventByKey('button1', 10, ""))); console.info("swiperTest_0800 click result is: " + JSON.stringify(sendEventByKey('button1', 10, "")));
await Utils.sleep(1000); await Utils.sleep(1000);
console.info('swiperTest_0800 END'); console.info('swiperTest_0800 END');
done();
}); });
it('swiperTest_0900', 0, async function (done) { it('swiperTest_0900', 0, async function (done) {
...@@ -186,6 +186,7 @@ export default function swiperJsunit() { ...@@ -186,6 +186,7 @@ export default function swiperJsunit() {
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("swiperTest_0900 get state result is: " + JSON.stringify(indexEvent)); console.info("swiperTest_0900 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.ACTION).assertEqual(true); expect(indexEvent.data.ACTION).assertEqual(true);
done();
} }
let indexEvent = { let indexEvent = {
eventId: 206, eventId: 206,
...@@ -199,7 +200,6 @@ export default function swiperJsunit() { ...@@ -199,7 +200,6 @@ export default function swiperJsunit() {
console.info("swiperTest_0900 click result is: " + JSON.stringify(sendEventByKey('button2', 10, ""))); console.info("swiperTest_0900 click result is: " + JSON.stringify(sendEventByKey('button2', 10, "")));
await Utils.sleep(1000); await Utils.sleep(1000);
console.info('swiperTest_0900 END'); console.info('swiperTest_0900 END');
done();
}); });
it('swiperTest_1000', 0, async function (done) { it('swiperTest_1000', 0, async function (done) {
...@@ -208,6 +208,7 @@ export default function swiperJsunit() { ...@@ -208,6 +208,7 @@ export default function swiperJsunit() {
let callbackOne = (indexEventOne) => { let callbackOne = (indexEventOne) => {
console.info("swiperTest_1000 get state result is: " + JSON.stringify(indexEventOne)); console.info("swiperTest_1000 get state result is: " + JSON.stringify(indexEventOne));
expect(indexEventOne.data.ACTION).assertEqual(true); expect(indexEventOne.data.ACTION).assertEqual(true);
done();
} }
let indexEventOne = { let indexEventOne = {
eventId: 206, eventId: 206,
...@@ -223,6 +224,7 @@ export default function swiperJsunit() { ...@@ -223,6 +224,7 @@ export default function swiperJsunit() {
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("swiperTest_1000 get state result is: " + JSON.stringify(indexEvent)); console.info("swiperTest_1000 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.ACTION).assertEqual(true); expect(indexEvent.data.ACTION).assertEqual(true);
done();
} }
let indexEvent = { let indexEvent = {
eventId: 204, eventId: 204,
...@@ -234,7 +236,6 @@ export default function swiperJsunit() { ...@@ -234,7 +236,6 @@ export default function swiperJsunit() {
console.info("swiperTest_1000 on events_emitter err : " + JSON.stringify(err)); console.info("swiperTest_1000 on events_emitter err : " + JSON.stringify(err));
} }
console.info('swiperTest_1000 END'); console.info('swiperTest_1000 END');
done();
}); });
it('swiperTest_1100', 0, async function (done) { it('swiperTest_1100', 0, async function (done) {
......
...@@ -60,6 +60,8 @@ export default function touchAbleJsunit() { ...@@ -60,6 +60,8 @@ export default function touchAbleJsunit() {
var callbackTwo = (eventData) => { var callbackTwo = (eventData) => {
console.info("[testTouchAble002] get event state result is: " + JSON.stringify(eventData)); console.info("[testTouchAble002] get event state result is: " + JSON.stringify(eventData));
expect(eventData.data.ACTION).assertEqual('Ellipse Clicked') expect(eventData.data.ACTION).assertEqual('Ellipse Clicked')
console.info('[testTouchAble002] END');
done();
} }
var innerEventTwo = { var innerEventTwo = {
eventId: 237, eventId: 237,
...@@ -70,10 +72,7 @@ export default function touchAbleJsunit() { ...@@ -70,10 +72,7 @@ export default function touchAbleJsunit() {
} catch (err) { } catch (err) {
console.info("[testTouchAble002] on events_emitter err : " + JSON.stringify(err)); console.info("[testTouchAble002] on events_emitter err : " + JSON.stringify(err));
} }
console.info('[testClickEvent001] sendEventByKey ' + JSON.stringify(sendEventByKey('ellipse', 10, ""))); console.info("testClickEvent002 click result is: " + JSON.stringify(sendEventByKey('ellipse', 10, "")));
await Utils.sleep(1000)
console.info('[testTouchAble002] END');
done();
}); });
}) })
} }
\ No newline at end of file
...@@ -55,6 +55,7 @@ export default function touchJsunit() { ...@@ -55,6 +55,7 @@ export default function touchJsunit() {
console.info("testTouch01 get backEvent result is: " + JSON.stringify(backEvent)); console.info("testTouch01 get backEvent result is: " + JSON.stringify(backEvent));
console.info("testTouch01 get flag result is: " + JSON.stringify(backData.data.ACTION)); console.info("testTouch01 get flag result is: " + JSON.stringify(backData.data.ACTION));
expect(backData.data.ACTION).assertEqual(true); expect(backData.data.ACTION).assertEqual(true);
done();
} }
var backEvent = { var backEvent = {
eventId: 43, eventId: 43,
...@@ -66,7 +67,6 @@ export default function touchJsunit() { ...@@ -66,7 +67,6 @@ export default function touchJsunit() {
} }
console.info("testTouch01 click result is: " + JSON.stringify(sendEventByKey('touch', 10, ""))); console.info("testTouch01 click result is: " + JSON.stringify(sendEventByKey('touch', 10, "")));
console.info('[testTouch01] END'); console.info('[testTouch01] END');
done();
}); });
}) })
} }
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册