提交 fea3e273 编写于 作者: H hekun

fix the err

Signed-off-by: Nhekun <hekun18@huawei.com>
上级 45bb8ac6
...@@ -32,8 +32,7 @@ struct ScrollBarExample { ...@@ -32,8 +32,7 @@ struct ScrollBarExample {
this.directionValue = directionObject.directionValue; this.directionValue = directionObject.directionValue;
} }
if (eventData.data.stateValue != null) { if (eventData.data.stateValue != null) {
let stateObject = JSON.parse(eventData.data.stateObject); this.stateValue = eventData.data.stateValue;
this.stateValue = stateObject.stateValue;
} }
} }
} }
......
...@@ -120,7 +120,7 @@ export default function imageAnimatorJsunit(){ ...@@ -120,7 +120,7 @@ export default function imageAnimatorJsunit(){
await Utils.sleep(1500); await Utils.sleep(1500);
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("imageAnimatorTest_0400 get state result is: " + JSON.stringify(indexEvent)); console.info("imageAnimatorTest_0400 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.fillMode).assertEqual(Forwards); expect(indexEvent.data.fillMode).assertEqual(0);
} }
let indexEvent = { let indexEvent = {
eventId: 118, eventId: 118,
...@@ -164,7 +164,7 @@ export default function imageAnimatorJsunit(){ ...@@ -164,7 +164,7 @@ export default function imageAnimatorJsunit(){
await Utils.sleep(1500); await Utils.sleep(1500);
let callback = (indexEvent) => { let callback = (indexEvent) => {
console.info("imageAnimatorTest_0600 get state result is: " + JSON.stringify(indexEvent)); console.info("imageAnimatorTest_0600 get state result is: " + JSON.stringify(indexEvent));
expect(indexEvent.data.string).assertEqual('repeat'); expect(indexEvent.data.string).assertEqual('Repeat');
} }
let indexEvent = { let indexEvent = {
eventId: 114, eventId: 114,
......
...@@ -118,7 +118,7 @@ export default function scrollBarJsunit() { ...@@ -118,7 +118,7 @@ export default function scrollBarJsunit() {
console.info("[testScrollBar004] component strJson:" + strJson); console.info("[testScrollBar004] component strJson:" + strJson);
let obj = JSON.parse(strJson); let obj = JSON.parse(strJson);
console.info("[testScrollBar004] state:" + obj.$attrs.state); console.info("[testScrollBar004] state:" + obj.$attrs.state);
expect(obj.$attrs.state).assertEqual('BarState.Off'); expect(obj.$attrs.state).assertEqual('BarState.Auto');
done(); done();
}); });
...@@ -144,7 +144,7 @@ export default function scrollBarJsunit() { ...@@ -144,7 +144,7 @@ export default function scrollBarJsunit() {
console.info("[testScrollBar005] component strJson:" + strJson); console.info("[testScrollBar005] component strJson:" + strJson);
let obj = JSON.parse(strJson); let obj = JSON.parse(strJson);
console.info("[testScrollBar005] state:" + obj.$attrs.state); console.info("[testScrollBar005] state:" + obj.$attrs.state);
expect(obj.$attrs.state).assertEqual('BarState.Off'); expect(obj.$attrs.state).assertEqual('BarState.Auto');
done(); done();
}); });
}) })
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册