提交 db61e164 编写于 作者: L liu-xu01

ACEcommit

Signed-off-by: Nliu-xu01 <l18612094222@163.com>
上级 3f450895
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function badgeJsunit() { ...@@ -30,7 +30,7 @@ export default function badgeJsunit() {
} }
describe('badgeTest', function () { describe('badgeTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Badge', uri: 'pages/Badge',
} }
...@@ -38,7 +38,7 @@ export default function badgeJsunit() { ...@@ -38,7 +38,7 @@ export default function badgeJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Badge state success " + JSON.stringify(pages)); console.info("get Badge state success " + JSON.stringify(pages));
if(!("Badge" == pages.name)){ if (!("Badge" == pages.name)) {
console.info("get Badge state success " + JSON.stringify(pages.name)); console.info("get Badge state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Badge page success " + JSON.stringify(result)); console.info("push Badge page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function badgeJsunit() { ...@@ -50,7 +50,7 @@ export default function badgeJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Badge after each called"); console.info("Badge after each called");
}); });
...@@ -113,5 +113,7 @@ export default function badgeJsunit() { ...@@ -113,5 +113,7 @@ export default function badgeJsunit() {
console.info('testGetInspectorByKey END'); console.info('testGetInspectorByKey END');
done(); done();
}); });
}) }
)
} }
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function blankJsunit() { ...@@ -30,7 +30,7 @@ export default function blankJsunit() {
} }
describe('BlankTest', function () { describe('BlankTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Blank', uri: 'pages/Blank',
} }
...@@ -38,7 +38,7 @@ export default function blankJsunit() { ...@@ -38,7 +38,7 @@ export default function blankJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Blank state success " + JSON.stringify(pages)); console.info("get Blank state success " + JSON.stringify(pages));
if(!("Blank" == pages.name)){ if (!("Blank" == pages.name)) {
console.info("get Blank state success " + JSON.stringify(pages.name)); console.info("get Blank state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Blank page success " + JSON.stringify(result)); console.info("push Blank page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function blankJsunit() { ...@@ -50,7 +50,7 @@ export default function blankJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Blank after each called"); console.info("Blank after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function buttonJsunit() { ...@@ -30,7 +30,7 @@ export default function buttonJsunit() {
} }
describe('buttonTest', function () { describe('buttonTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Button', uri: 'pages/Button',
} }
...@@ -38,7 +38,7 @@ export default function buttonJsunit() { ...@@ -38,7 +38,7 @@ export default function buttonJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Button state success " + JSON.stringify(pages)); console.info("get Button state success " + JSON.stringify(pages));
if(!("Button" == pages.name)){ if (!("Button" == pages.name)) {
console.info("get Button state success " + JSON.stringify(pages.name)); console.info("get Button state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Button page success " + JSON.stringify(result)); console.info("push Button page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function buttonJsunit() { ...@@ -50,7 +50,7 @@ export default function buttonJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Button after each called"); console.info("Button after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function columnJsunit() { ...@@ -30,7 +30,7 @@ export default function columnJsunit() {
} }
describe('columnTest', function () { describe('columnTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Column', uri: 'pages/Column',
} }
...@@ -38,7 +38,7 @@ export default function columnJsunit() { ...@@ -38,7 +38,7 @@ export default function columnJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Column state success " + JSON.stringify(pages)); console.info("get Column state success " + JSON.stringify(pages));
if(!("Column" == pages.name)){ if (!("Column" == pages.name)) {
console.info("get Column state success " + JSON.stringify(pages.name)); console.info("get Column state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Column page success " + JSON.stringify(result)); console.info("push Column page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function columnJsunit() { ...@@ -50,7 +50,7 @@ export default function columnJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Column after each called"); console.info("Column after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function columnSplitJsunit() { ...@@ -30,7 +30,7 @@ export default function columnSplitJsunit() {
} }
describe('columnSplitTest', function () { describe('columnSplitTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/ColumnSplit', uri: 'pages/ColumnSplit',
} }
...@@ -38,7 +38,7 @@ export default function columnSplitJsunit() { ...@@ -38,7 +38,7 @@ export default function columnSplitJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get ColumnSplit state success " + JSON.stringify(pages)); console.info("get ColumnSplit state success " + JSON.stringify(pages));
if(!("ColumnSplit" == pages.name)){ if (!("ColumnSplit" == pages.name)) {
console.info("get ColumnSplit state success " + JSON.stringify(pages.name)); console.info("get ColumnSplit state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push ColumnSplit page success " + JSON.stringify(result)); console.info("push ColumnSplit page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function columnSplitJsunit() { ...@@ -50,7 +50,7 @@ export default function columnSplitJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("ColumnSplit after each called"); console.info("ColumnSplit after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function counterJsunit() { ...@@ -30,7 +30,7 @@ export default function counterJsunit() {
} }
describe('counterTest', function () { describe('counterTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Counter', uri: 'pages/Counter',
} }
...@@ -38,7 +38,7 @@ export default function counterJsunit() { ...@@ -38,7 +38,7 @@ export default function counterJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Counter state success " + JSON.stringify(pages)); console.info("get Counter state success " + JSON.stringify(pages));
if(!("Counter" == pages.name)){ if (!("Counter" == pages.name)) {
console.info("get Counter state success " + JSON.stringify(pages.name)); console.info("get Counter state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Counter page success " + JSON.stringify(result)); console.info("push Counter page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function counterJsunit() { ...@@ -50,7 +50,7 @@ export default function counterJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Counter after each called"); console.info("Counter after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,15 +30,15 @@ export default function datapanelJsunit() { ...@@ -30,15 +30,15 @@ export default function datapanelJsunit() {
} }
describe('dataPanelTest', function () { describe('dataPanelTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/DataPanel', uri: 'pages/DataPanel',
} }
try { try {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get DataPanel state success " + JSON.stringify(pages)); console.info("get DataPanel state success " + JSON.stringify(pages));
if(!("DataPanel" == pages.name)){ if (!("DataPanel" == pages.name)) {
console.info("get DataPanel state success " + JSON.stringify(pages.name)); console.info("get DataPanel state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push DataPanel page success " + JSON.stringify(result)); console.info("push DataPanel page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function datapanelJsunit() { ...@@ -50,7 +50,7 @@ export default function datapanelJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("DataPanel after each called"); console.info("DataPanel after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function dividerJsunit() { ...@@ -30,7 +30,7 @@ export default function dividerJsunit() {
} }
describe('dividerTest', function () { describe('dividerTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Divider', uri: 'pages/Divider',
} }
...@@ -38,10 +38,11 @@ export default function dividerJsunit() { ...@@ -38,10 +38,11 @@ export default function dividerJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get divider state success " + JSON.stringify(pages)); console.info("get divider state success " + JSON.stringify(pages));
if(!("Divider" == pages.name)){ if (!("Divider" == pages.name)) {
console.info("get divider state success " + JSON.stringify(pages.name)); console.info("get divider state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push divider page success " + JSON.stringify(result));} console.info("push divider page success " + JSON.stringify(result));
}
} catch (err) { } catch (err) {
console.error("push divider page error " + JSON.stringify(result)); console.error("push divider page error " + JSON.stringify(result));
} }
...@@ -49,7 +50,7 @@ export default function dividerJsunit() { ...@@ -49,7 +50,7 @@ export default function dividerJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Divider after each called"); console.info("Divider after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function flexJsunit() { ...@@ -30,7 +30,7 @@ export default function flexJsunit() {
} }
describe('flexTest', function () { describe('flexTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Flex', uri: 'pages/Flex',
} }
...@@ -38,7 +38,7 @@ export default function flexJsunit() { ...@@ -38,7 +38,7 @@ export default function flexJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Flex state success " + JSON.stringify(pages)); console.info("get Flex state success " + JSON.stringify(pages));
if(!("Flex" == pages.name)){ if (!("Flex" == pages.name)) {
console.info("get Flex state success " + JSON.stringify(pages.name)); console.info("get Flex state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Flex page success " + JSON.stringify(result)); console.info("push Flex page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function flexJsunit() { ...@@ -50,7 +50,7 @@ export default function flexJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Flex after each called"); console.info("Flex after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function gridContainerJsunit() { ...@@ -30,7 +30,7 @@ export default function gridContainerJsunit() {
} }
describe('gridContainerTest', function () { describe('gridContainerTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/GridContainer', uri: 'pages/GridContainer',
} }
...@@ -38,7 +38,7 @@ export default function gridContainerJsunit() { ...@@ -38,7 +38,7 @@ export default function gridContainerJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get GridContainer state success " + JSON.stringify(pages)); console.info("get GridContainer state success " + JSON.stringify(pages));
if(!("GridContainer" == pages.name)){ if (!("GridContainer" == pages.name)) {
console.info("get GridContainer state success " + JSON.stringify(pages.name)); console.info("get GridContainer state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push GridContainer page success " + JSON.stringify(result)); console.info("push GridContainer page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function gridContainerJsunit() { ...@@ -50,7 +50,7 @@ export default function gridContainerJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("GridContainer after each called"); console.info("GridContainer after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function imageJsunit() { ...@@ -30,7 +30,7 @@ export default function imageJsunit() {
} }
describe('imageTest', function () { describe('imageTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Image', uri: 'pages/Image',
} }
...@@ -38,7 +38,7 @@ export default function imageJsunit() { ...@@ -38,7 +38,7 @@ export default function imageJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Image state success " + JSON.stringify(pages)); console.info("get Image state success " + JSON.stringify(pages));
if(!("Image" == pages.name)){ if (!("Image" == pages.name)) {
console.info("get Image state success " + JSON.stringify(pages.name)); console.info("get Image state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Image page success " + JSON.stringify(result)); console.info("push Image page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function imageJsunit() { ...@@ -50,7 +50,7 @@ export default function imageJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Image after each called"); console.info("Image after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function panelJsunit() { ...@@ -30,7 +30,7 @@ export default function panelJsunit() {
} }
describe('panelTest', function () { describe('panelTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Panel', uri: 'pages/Panel',
} }
...@@ -38,19 +38,19 @@ export default function panelJsunit() { ...@@ -38,19 +38,19 @@ export default function panelJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Panel state success " + JSON.stringify(pages)); console.info("get Panel state success " + JSON.stringify(pages));
if(!("Panel" == pages.name)){ if (!("Panel" == pages.name)) {
console.info("get Panel state success " + JSON.stringify(pages.name)); console.info("get Panel state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Panel page success " + JSON.stringify(result)); console.info("push Panel page success " + JSON.stringify(result));
} }
} catch (err) { } catch (err) {
console.error(JSON.stringify(result)); console.error(JSON.stringify(result));
} }
await sleep(1) await sleep(1)
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Panel after each called"); console.info("Panel after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,15 +30,15 @@ export default function progressJsunit() { ...@@ -30,15 +30,15 @@ export default function progressJsunit() {
} }
describe('progressTest', function () { describe('progressTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Progress', uri: 'pages/Progress',
} }
try { try {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Progress state success " + JSON.stringify(pages)); console.info("get Progress state success " + JSON.stringify(pages));
if(!("Progress" == pages.name)){ if (!("Progress" == pages.name)) {
console.info("get Progress state success " + JSON.stringify(pages.name)); console.info("get Progress state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Progress page success " + JSON.stringify(result)); console.info("push Progress page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function progressJsunit() { ...@@ -50,7 +50,7 @@ export default function progressJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Progress after each called"); console.info("Progress after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function qrcodeJsunit() { ...@@ -30,7 +30,7 @@ export default function qrcodeJsunit() {
} }
describe('QrcodeTest', function () { describe('QrcodeTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Qrcode', uri: 'pages/Qrcode',
} }
...@@ -38,7 +38,7 @@ export default function qrcodeJsunit() { ...@@ -38,7 +38,7 @@ export default function qrcodeJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Qrcode state success " + JSON.stringify(pages)); console.info("get Qrcode state success " + JSON.stringify(pages));
if(!("Qrcode" == pages.name)){ if (!("Qrcode" == pages.name)) {
console.info("get Qrcode state success " + JSON.stringify(pages.name)); console.info("get Qrcode state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Qrcode page success " + JSON.stringify(result)); console.info("push Qrcode page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function qrcodeJsunit() { ...@@ -50,7 +50,7 @@ export default function qrcodeJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Qrcode after each called"); console.info("Qrcode after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function ratingJsunit() { ...@@ -30,7 +30,7 @@ export default function ratingJsunit() {
} }
describe('ratingTest', function () { describe('ratingTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Rating', uri: 'pages/Rating',
} }
...@@ -38,7 +38,7 @@ export default function ratingJsunit() { ...@@ -38,7 +38,7 @@ export default function ratingJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Rating state success " + JSON.stringify(pages)); console.info("get Rating state success " + JSON.stringify(pages));
if(!("Rating" == pages.name)){ if (!("Rating" == pages.name)) {
console.info("get Rating state success " + JSON.stringify(pages.name)); console.info("get Rating state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Rating page success " + JSON.stringify(result)); console.info("push Rating page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function ratingJsunit() { ...@@ -50,7 +50,7 @@ export default function ratingJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Rating after each called"); console.info("Rating after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function rowSplitJsunit() { ...@@ -30,7 +30,7 @@ export default function rowSplitJsunit() {
} }
describe('RowSplitTest', function () { describe('RowSplitTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/RowSplit', uri: 'pages/RowSplit',
} }
...@@ -38,7 +38,7 @@ export default function rowSplitJsunit() { ...@@ -38,7 +38,7 @@ export default function rowSplitJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get RowSplit state success " + JSON.stringify(pages)); console.info("get RowSplit state success " + JSON.stringify(pages));
if(!("RowSplit" == pages.name)){ if (!("RowSplit" == pages.name)) {
console.info("get RowSplit state success " + JSON.stringify(pages.name)); console.info("get RowSplit state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push RowSplit page success " + JSON.stringify(result)); console.info("push RowSplit page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function rowSplitJsunit() { ...@@ -50,7 +50,7 @@ export default function rowSplitJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("RowSplit after each called"); console.info("RowSplit after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function ScrollJsunit() { ...@@ -30,7 +30,7 @@ export default function ScrollJsunit() {
} }
describe('scrollTest', function () { describe('scrollTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Scroll', uri: 'pages/Scroll',
} }
...@@ -38,7 +38,7 @@ export default function ScrollJsunit() { ...@@ -38,7 +38,7 @@ export default function ScrollJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Scroll state success " + JSON.stringify(pages)); console.info("get Scroll state success " + JSON.stringify(pages));
if(!("Scroll" == pages.name)){ if (!("Scroll" == pages.name)) {
console.info("get Scroll state success " + JSON.stringify(pages.name)); console.info("get Scroll state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Scroll page success " + JSON.stringify(result)); console.info("push Scroll page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function ScrollJsunit() { ...@@ -50,7 +50,7 @@ export default function ScrollJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Scroll after each called"); console.info("Scroll after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function sliderJsunit() { ...@@ -30,7 +30,7 @@ export default function sliderJsunit() {
} }
describe('SliderTest', function () { describe('SliderTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Slider', uri: 'pages/Slider',
} }
...@@ -38,7 +38,7 @@ export default function sliderJsunit() { ...@@ -38,7 +38,7 @@ export default function sliderJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Slider state success " + JSON.stringify(pages)); console.info("get Slider state success " + JSON.stringify(pages));
if(!("Slider" == pages.name)){ if (!("Slider" == pages.name)) {
console.info("get Slider state success " + JSON.stringify(pages.name)); console.info("get Slider state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Slider page success " + JSON.stringify(result)); console.info("push Slider page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function sliderJsunit() { ...@@ -50,7 +50,7 @@ export default function sliderJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Slider after each called"); console.info("Slider after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function spanJsunit() { ...@@ -30,7 +30,7 @@ export default function spanJsunit() {
} }
describe('SpanTest', function () { describe('SpanTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Span', uri: 'pages/Span',
} }
...@@ -38,7 +38,7 @@ export default function spanJsunit() { ...@@ -38,7 +38,7 @@ export default function spanJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Span state success " + JSON.stringify(pages)); console.info("get Span state success " + JSON.stringify(pages));
if(!("Span" == pages.name)){ if (!("Span" == pages.name)) {
console.info("get Span state success " + JSON.stringify(pages.name)); console.info("get Span state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Span page success " + JSON.stringify(result)); console.info("push Span page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function spanJsunit() { ...@@ -50,7 +50,7 @@ export default function spanJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Span after each called"); console.info("Span after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function StackJsunit() { ...@@ -30,7 +30,7 @@ export default function StackJsunit() {
} }
describe('StackTest', function () { describe('StackTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Stack', uri: 'pages/Stack',
} }
...@@ -38,7 +38,7 @@ export default function StackJsunit() { ...@@ -38,7 +38,7 @@ export default function StackJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Stack state success " + JSON.stringify(pages)); console.info("get Stack state success " + JSON.stringify(pages));
if(!("Stack" == pages.name)){ if (!("Stack" == pages.name)) {
console.info("get Stack state success " + JSON.stringify(pages.name)); console.info("get Stack state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Stack page success " + JSON.stringify(result)); console.info("push Stack page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function StackJsunit() { ...@@ -50,7 +50,7 @@ export default function StackJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Stack after each called"); console.info("Stack after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,7 +30,7 @@ export default function textJsunit() { ...@@ -30,7 +30,7 @@ export default function textJsunit() {
} }
describe('textTest', function () { describe('textTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Text', uri: 'pages/Text',
} }
...@@ -38,7 +38,7 @@ export default function textJsunit() { ...@@ -38,7 +38,7 @@ export default function textJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Text state success " + JSON.stringify(pages)); console.info("get Text state success " + JSON.stringify(pages));
if(!("Text" == pages.name)){ if (!("Text" == pages.name)) {
console.info("get Text state success " + JSON.stringify(pages.name)); console.info("get Text state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Text page success " + JSON.stringify(result)); console.info("push Text page success " + JSON.stringify(result));
...@@ -50,7 +50,7 @@ export default function textJsunit() { ...@@ -50,7 +50,7 @@ export default function textJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Text after each called"); console.info("Text after each called");
}); });
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,16 +30,15 @@ export default function alphabetIndexerJsunit() { ...@@ -30,16 +30,15 @@ export default function alphabetIndexerJsunit() {
} }
describe('alphabetIndexerTest', function () { describe('alphabetIndexerTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){ let options = {
let options = {
uri: 'pages/AlphabetIndexer', uri: 'pages/AlphabetIndexer',
} }
try { try {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get AlphabetIndexer state success " + JSON.stringify(pages)); console.info("get AlphabetIndexer state success " + JSON.stringify(pages));
if(!("AlphabetIndexer" == pages.name)){ if (!("AlphabetIndexer" == pages.name)) {
console.info("get AlphabetIndexer state success " + JSON.stringify(pages.name)); console.info("get AlphabetIndexer state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push AlphabetIndexer page success " + JSON.stringify(result)); console.info("push AlphabetIndexer page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function alphabetIndexerJsunit() { ...@@ -51,7 +50,7 @@ export default function alphabetIndexerJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("AlphabetIndexer after each called"); console.info("AlphabetIndexer after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,8 +30,7 @@ export default function appStorageJsunit() { ...@@ -30,8 +30,7 @@ export default function appStorageJsunit() {
} }
describe('appStorageTest', function () { describe('appStorageTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/AppStorage', uri: 'pages/AppStorage',
} }
...@@ -39,7 +38,7 @@ export default function appStorageJsunit() { ...@@ -39,7 +38,7 @@ export default function appStorageJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get AppStorage state success " + JSON.stringify(pages)); console.info("get AppStorage state success " + JSON.stringify(pages));
if(!("AppStorage" == pages.name)){ if (!("AppStorage" == pages.name)) {
console.info("get AppStorage state success " + JSON.stringify(pages.name)); console.info("get AppStorage state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push AppStorage page success " + JSON.stringify(result)); console.info("push AppStorage page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function appStorageJsunit() { ...@@ -51,7 +50,7 @@ export default function appStorageJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("AppStorage after each called"); console.info("AppStorage after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,8 +30,7 @@ export default function gridItemJsunit() { ...@@ -30,8 +30,7 @@ export default function gridItemJsunit() {
} }
describe('gridItemTest', function () { describe('gridItemTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/GridItem', uri: 'pages/GridItem',
} }
...@@ -39,7 +38,7 @@ export default function gridItemJsunit() { ...@@ -39,7 +38,7 @@ export default function gridItemJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get GridItem state success " + JSON.stringify(pages)); console.info("get GridItem state success " + JSON.stringify(pages));
if(!("GridItem" == pages.name)){ if (!("GridItem" == pages.name)) {
console.info("get GridItem state success " + JSON.stringify(pages.name)); console.info("get GridItem state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push GridItem page success " + JSON.stringify(result)); console.info("push GridItem page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function gridItemJsunit() { ...@@ -51,7 +50,7 @@ export default function gridItemJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("GridItem after each called"); console.info("GridItem after each called");
}); });
...@@ -69,11 +68,11 @@ export default function gridItemJsunit() { ...@@ -69,11 +68,11 @@ export default function gridItemJsunit() {
console.info("属性值集合: " + JSON.stringify(obj)); console.info("属性值集合: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('GridItem') expect(obj.$type).assertEqual('GridItem')
console.log('GridItem1‘s rowStart is '+JSON.stringify(obj.$attrs.rowStart)) console.log('GridItem1‘s rowStart is ' + JSON.stringify(obj.$attrs.rowStart))
console.log('GridItem1‘s rowEnd is '+JSON.stringify(obj.$attrs.rowEnd)) console.log('GridItem1‘s rowEnd is ' + JSON.stringify(obj.$attrs.rowEnd))
console.log('GridItem1‘s columnStart is '+JSON.stringify(obj.$attrs.columnStart)) console.log('GridItem1‘s columnStart is ' + JSON.stringify(obj.$attrs.columnStart))
console.log('GridItem1‘s columnEnd is '+JSON.stringify(obj.$attrs.columnEnd)) console.log('GridItem1‘s columnEnd is ' + JSON.stringify(obj.$attrs.columnEnd))
console.log('GridItem1‘s forceRebuild is '+JSON.stringify(obj.$attrs.forceRebuild)) console.log('GridItem1‘s forceRebuild is ' + JSON.stringify(obj.$attrs.forceRebuild))
await sleep(1) await sleep(1)
expect(obj.$attrs.rowStart).assertEqual('1') expect(obj.$attrs.rowStart).assertEqual('1')
expect(obj.$attrs.rowEnd).assertEqual('4') expect(obj.$attrs.rowEnd).assertEqual('4')
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,16 +30,15 @@ export default function gridJsunit() { ...@@ -30,16 +30,15 @@ export default function gridJsunit() {
} }
describe('gridTest', function () { describe('gridTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/Grid', uri: 'pages/Grid',
} }
try { try {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Grid state success " + JSON.stringify(pages)); console.info("get Grid state success " + JSON.stringify(pages));
if(!("Grid" == pages.name)){ if (!("Grid" == pages.name)) {
console.info("get Grid state success " + JSON.stringify(pages.name)); console.info("get Grid state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Grid page success " + JSON.stringify(result)); console.info("push Grid page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function gridJsunit() { ...@@ -51,7 +50,7 @@ export default function gridJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Grid after each called"); console.info("Grid after each called");
}); });
...@@ -80,5 +79,7 @@ export default function gridJsunit() { ...@@ -80,5 +79,7 @@ export default function gridJsunit() {
console.info('gridTest001 END'); console.info('gridTest001 END');
done(); done();
}); });
}) }
)
} }
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,8 +30,7 @@ export default function hyperlinkJsunit() { ...@@ -30,8 +30,7 @@ export default function hyperlinkJsunit() {
} }
describe('hyperLinkTest', function () { describe('hyperLinkTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/HyperLink', uri: 'pages/HyperLink',
} }
...@@ -39,7 +38,7 @@ export default function hyperlinkJsunit() { ...@@ -39,7 +38,7 @@ export default function hyperlinkJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get HyperLink state success " + JSON.stringify(pages)); console.info("get HyperLink state success " + JSON.stringify(pages));
if(!("HyperLink" == pages.name)){ if (!("HyperLink" == pages.name)) {
console.info("get HyperLink state success " + JSON.stringify(pages.name)); console.info("get HyperLink state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push HyperLink page success " + JSON.stringify(result)); console.info("push HyperLink page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function hyperlinkJsunit() { ...@@ -51,7 +50,7 @@ export default function hyperlinkJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("HyperLink after each called"); console.info("HyperLink after each called");
}); });
...@@ -68,8 +67,8 @@ export default function hyperlinkJsunit() { ...@@ -68,8 +67,8 @@ export default function hyperlinkJsunit() {
let obj = JSON.parse(strJson); let obj = JSON.parse(strJson);
expect(obj.$type).assertEqual('Hyperlink') expect(obj.$type).assertEqual('Hyperlink')
console.info("属性值集合: " + JSON.stringify(obj)); console.info("属性值集合: " + JSON.stringify(obj));
console.log('Hyperlink‘s address is '+JSON.stringify(obj.$attrs.address)) console.log('Hyperlink‘s address is ' + JSON.stringify(obj.$attrs.address))
console.log('Hyperlink‘s content is '+JSON.stringify(obj.$attrs.content)) console.log('Hyperlink‘s content is ' + JSON.stringify(obj.$attrs.content))
expect(obj.$attrs.address).assertEqual('https://developer.harmonyos.com/') expect(obj.$attrs.address).assertEqual('https://developer.harmonyos.com/')
expect(obj.$attrs.content).assertEqual('Go to the developer website') expect(obj.$attrs.content).assertEqual('Go to the developer website')
console.info('++++++++++++++++ Hyperlink TestCase 1 End ++++++++++++++++'); console.info('++++++++++++++++ Hyperlink TestCase 1 End ++++++++++++++++');
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -31,8 +31,7 @@ export default function linkJsunit() { ...@@ -31,8 +31,7 @@ export default function linkJsunit() {
describe('linkTest', function () { describe('linkTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/Link', uri: 'pages/Link',
} }
...@@ -40,7 +39,7 @@ export default function linkJsunit() { ...@@ -40,7 +39,7 @@ export default function linkJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Link state success " + JSON.stringify(pages)); console.info("get Link state success " + JSON.stringify(pages));
if(!("Link" == pages.name)){ if (!("Link" == pages.name)) {
console.info("get Link state success " + JSON.stringify(pages.name)); console.info("get Link state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Link page success " + JSON.stringify(result)); console.info("push Link page success " + JSON.stringify(result));
...@@ -52,7 +51,7 @@ export default function linkJsunit() { ...@@ -52,7 +51,7 @@ export default function linkJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Link after each called"); console.info("Link after each called");
}); });
...@@ -72,7 +71,7 @@ export default function linkJsunit() { ...@@ -72,7 +71,7 @@ export default function linkJsunit() {
console.info("yr link0 type: " + JSON.stringify(obj.$type)); console.info("yr link0 type: " + JSON.stringify(obj.$type));
console.info("component obj is: " + JSON.stringify(obj)); console.info("component obj is: " + JSON.stringify(obj));
expect(obj.$attrs.stateEffect).assertEqual('false'); expect(obj.$attrs.stateEffect).assertEqual('false');
console.log("yr link0 stateEffect-'false'"+JSON.stringify(obj.$attrs.stateEffect)) console.log("yr link0 stateEffect-'false'" + JSON.stringify(obj.$attrs.stateEffect))
console.info('linkTest001 END'); console.info('linkTest001 END');
done(); done();
}); });
...@@ -88,7 +87,7 @@ export default function linkJsunit() { ...@@ -88,7 +87,7 @@ export default function linkJsunit() {
let obj = JSON.parse(strJson); let obj = JSON.parse(strJson);
console.info("component obj is: " + JSON.stringify(obj)); console.info("component obj is: " + JSON.stringify(obj));
expect(obj.$attrs.stateEffect).assertEqual('false'); expect(obj.$attrs.stateEffect).assertEqual('false');
console.log("yr link1 stateEffect-'false'"+JSON.stringify(obj.$attrs.stateEffect)) console.log("yr link1 stateEffect-'false'" + JSON.stringify(obj.$attrs.stateEffect))
console.info('linkTest002 END'); console.info('linkTest002 END');
done(); done();
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,16 +30,15 @@ export default function listItemJsunit() { ...@@ -30,16 +30,15 @@ export default function listItemJsunit() {
} }
describe('listItemTest', function () { describe('listItemTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/ListItem', uri: 'pages/ListItem',
} }
try { try {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get ListItem state success " + JSON.stringify(pages)); console.info("get ListItem state success " + JSON.stringify(pages));
if(!("ListItem" == pages.name)){ if (!("ListItem" == pages.name)) {
console.info("get ListItem state success " + JSON.stringify(pages.name)); console.info("get ListItem state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push ListItem page success " + JSON.stringify(result)); console.info("push ListItem page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function listItemJsunit() { ...@@ -51,7 +50,7 @@ export default function listItemJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("ListItem after each called"); console.info("ListItem after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,8 +30,7 @@ export default function listJsunit() { ...@@ -30,8 +30,7 @@ export default function listJsunit() {
} }
describe('listTest', function () { describe('listTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/List', uri: 'pages/List',
} }
...@@ -39,7 +38,7 @@ export default function listJsunit() { ...@@ -39,7 +38,7 @@ export default function listJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get List state success " + JSON.stringify(pages)); console.info("get List state success " + JSON.stringify(pages));
if(!("List" == pages.name)){ if (!("List" == pages.name)) {
console.info("get List state success " + JSON.stringify(pages.name)); console.info("get List state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push List page success " + JSON.stringify(result)); console.info("push List page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function listJsunit() { ...@@ -51,7 +50,7 @@ export default function listJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("List after each called"); console.info("List after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -30,8 +30,7 @@ export default function navigatorJsunit() { ...@@ -30,8 +30,7 @@ export default function navigatorJsunit() {
} }
describe('navigatorTest', function () { describe('navigatorTest', function () {
beforeEach(async function (done) {
beforeEach(async function(done){
let options = { let options = {
uri: 'pages/Navigator', uri: 'pages/Navigator',
} }
...@@ -39,7 +38,7 @@ export default function navigatorJsunit() { ...@@ -39,7 +38,7 @@ export default function navigatorJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Navigator state success " + JSON.stringify(pages)); console.info("get Navigator state success " + JSON.stringify(pages));
if(!("Navigator" == pages.name)){ if (!("Navigator" == pages.name)) {
console.info("get Navigator state success " + JSON.stringify(pages.name)); console.info("get Navigator state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Navigator page success " + JSON.stringify(result)); console.info("push Navigator page success " + JSON.stringify(result));
...@@ -51,7 +50,7 @@ export default function navigatorJsunit() { ...@@ -51,7 +50,7 @@ export default function navigatorJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Navigator after each called"); console.info("Navigator after each called");
}); });
...@@ -69,14 +68,16 @@ export default function navigatorJsunit() { ...@@ -69,14 +68,16 @@ export default function navigatorJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Navigator') expect(obj.$type).assertEqual('Navigator')
console.log('Navigator‘s target is '+JSON.stringify(obj.$attrs.target)) console.log('Navigator‘s target is ' + JSON.stringify(obj.$attrs.target))
console.log('Navigator‘s type is '+JSON.stringify(obj.$attrs.type)) console.log('Navigator‘s type is ' + JSON.stringify(obj.$attrs.type))
console.log('Navigator‘s active is '+JSON.stringify(obj.$attrs.active)) console.log('Navigator‘s active is ' + JSON.stringify(obj.$attrs.active))
console.log('Navigator‘s params is '+JSON.stringify(obj.$attrs.params)) console.log('Navigator‘s params is ' + JSON.stringify(obj.$attrs.params))
expect(obj.$attrs.target).assertEqual('pages/index') expect(obj.$attrs.target).assertEqual('pages/index')
expect(obj.$attrs.type).assertEqual('NavigationType.Back') expect(obj.$attrs.type).assertEqual('NavigationType.Back')
expect(obj.$attrs.active).assertEqual('false') expect(obj.$attrs.active).assertEqual('false')
expect(obj.$attrs.params).assertEqual(JSON.stringify({"data":24})) expect(obj.$attrs.params).assertEqual(JSON.stringify({
"data": 24
}))
console.info('++++++++++++++++ Navigator TestCase 1 End ++++++++++++++++'); console.info('++++++++++++++++ Navigator TestCase 1 End ++++++++++++++++');
done(); done();
}); });
...@@ -94,7 +95,7 @@ export default function navigatorJsunit() { ...@@ -94,7 +95,7 @@ export default function navigatorJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Navigator') expect(obj.$type).assertEqual('Navigator')
console.log('Navigator‘s type is '+JSON.stringify(obj.$attrs.type)) console.log('Navigator‘s type is ' + JSON.stringify(obj.$attrs.type))
expect(obj.$attrs.type).assertEqual('NavigationType.Push') expect(obj.$attrs.type).assertEqual('NavigationType.Push')
console.info('++++++++++++++++ Navigator TestCase 2 End ++++++++++++++++'); console.info('++++++++++++++++ Navigator TestCase 2 End ++++++++++++++++');
done(); done();
...@@ -113,7 +114,7 @@ export default function navigatorJsunit() { ...@@ -113,7 +114,7 @@ export default function navigatorJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Navigator') expect(obj.$type).assertEqual('Navigator')
console.log('Navigator‘s type is '+JSON.stringify(obj.$attrs.type)) console.log('Navigator‘s type is ' + JSON.stringify(obj.$attrs.type))
expect(obj.$attrs.type).assertEqual('NavigationType.Replace') expect(obj.$attrs.type).assertEqual('NavigationType.Replace')
console.info('++++++++++++++++ Navigator TestCase 3 End ++++++++++++++++'); console.info('++++++++++++++++ Navigator TestCase 3 End ++++++++++++++++');
done(); done();
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -31,7 +31,7 @@ export default function panelJsunit() { ...@@ -31,7 +31,7 @@ export default function panelJsunit() {
describe('panelTest', function () { describe('panelTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Panel', uri: 'pages/Panel',
} }
...@@ -39,7 +39,7 @@ export default function panelJsunit() { ...@@ -39,7 +39,7 @@ export default function panelJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Panel state success " + JSON.stringify(pages)); console.info("get Panel state success " + JSON.stringify(pages));
if(!("Panel" == pages.name)){ if (!("Panel" == pages.name)) {
console.info("get Panel state success " + JSON.stringify(pages.name)); console.info("get Panel state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Panel page success " + JSON.stringify(result)); console.info("push Panel page success " + JSON.stringify(result));
...@@ -51,7 +51,7 @@ export default function panelJsunit() { ...@@ -51,7 +51,7 @@ export default function panelJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Panel after each called"); console.info("Panel after each called");
}); });
...@@ -68,12 +68,12 @@ export default function panelJsunit() { ...@@ -68,12 +68,12 @@ export default function panelJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Panel') expect(obj.$type).assertEqual('Panel')
console.log('Panel‘s type is '+JSON.stringify(obj.$attrs.type)) console.log('Panel‘s type is ' + JSON.stringify(obj.$attrs.type))
console.log('Panel‘s mode is '+JSON.stringify(obj.$attrs.mode)) console.log('Panel‘s mode is ' + JSON.stringify(obj.$attrs.mode))
console.log('Panel‘s dragBar is '+JSON.stringify(obj.$attrs.dragBar)) console.log('Panel‘s dragBar is ' + JSON.stringify(obj.$attrs.dragBar))
console.log('Panel‘s fullHeight is '+JSON.stringify(obj.$attrs.fullHeight)) console.log('Panel‘s fullHeight is ' + JSON.stringify(obj.$attrs.fullHeight))
console.log('Panel‘s halfHeight is '+JSON.stringify(obj.$attrs.halfHeight)) console.log('Panel‘s halfHeight is ' + JSON.stringify(obj.$attrs.halfHeight))
console.log('Panel‘s miniHeight is '+JSON.stringify(obj.$attrs.miniHeight)) console.log('Panel‘s miniHeight is ' + JSON.stringify(obj.$attrs.miniHeight))
expect(obj.$attrs.type).assertEqual('PanelType.Foldable') expect(obj.$attrs.type).assertEqual('PanelType.Foldable')
expect(obj.$attrs.mode).assertEqual('PanelMode.Half') expect(obj.$attrs.mode).assertEqual('PanelMode.Half')
expect(obj.$attrs.dragBar).assertEqual('true') expect(obj.$attrs.dragBar).assertEqual('true')
...@@ -97,9 +97,9 @@ export default function panelJsunit() { ...@@ -97,9 +97,9 @@ export default function panelJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Panel') expect(obj.$type).assertEqual('Panel')
console.log('Panel‘s type is '+JSON.stringify(obj.$attrs.type)) console.log('Panel‘s type is ' + JSON.stringify(obj.$attrs.type))
console.log('Panel‘s mode is '+JSON.stringify(obj.$attrs.mode)) console.log('Panel‘s mode is ' + JSON.stringify(obj.$attrs.mode))
console.log('Panel‘s show is '+JSON.stringify(obj.$attrs.show)) console.log('Panel‘s show is ' + JSON.stringify(obj.$attrs.show))
expect(obj.$attrs.type).assertEqual('PanelType.Minibar') expect(obj.$attrs.type).assertEqual('PanelType.Minibar')
expect(obj.$attrs.mode).assertEqual('PanelMode.Mini') expect(obj.$attrs.mode).assertEqual('PanelMode.Mini')
expect(obj.$attrs.show).assertEqual('true') expect(obj.$attrs.show).assertEqual('true')
...@@ -120,9 +120,9 @@ export default function panelJsunit() { ...@@ -120,9 +120,9 @@ export default function panelJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Panel') expect(obj.$type).assertEqual('Panel')
console.log('Panel‘s type is '+JSON.stringify(obj.$attrs.type)) console.log('Panel‘s type is ' + JSON.stringify(obj.$attrs.type))
console.log('Panel‘s mode is '+JSON.stringify(obj.$attrs.mode)) console.log('Panel‘s mode is ' + JSON.stringify(obj.$attrs.mode))
console.log('Panel‘s show is '+JSON.stringify(obj.$attrs.show)) console.log('Panel‘s show is ' + JSON.stringify(obj.$attrs.show))
expect(obj.$attrs.type).assertEqual('PanelType.Temporary') expect(obj.$attrs.type).assertEqual('PanelType.Temporary')
expect(obj.$attrs.mode).assertEqual('PanelMode.Full') expect(obj.$attrs.mode).assertEqual('PanelMode.Full')
expect(obj.$attrs.show).assertEqual('false') expect(obj.$attrs.show).assertEqual('false')
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -31,7 +31,7 @@ export default function propJsunit() { ...@@ -31,7 +31,7 @@ export default function propJsunit() {
describe('propTest', function () { describe('propTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Prop', uri: 'pages/Prop',
} }
...@@ -39,7 +39,7 @@ export default function propJsunit() { ...@@ -39,7 +39,7 @@ export default function propJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Prop state success " + JSON.stringify(pages)); console.info("get Prop state success " + JSON.stringify(pages));
if(!("Prop" == pages.name)){ if (!("Prop" == pages.name)) {
console.info("get Prop state success " + JSON.stringify(pages.name)); console.info("get Prop state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Prop page success " + JSON.stringify(result)); console.info("push Prop page success " + JSON.stringify(result));
...@@ -51,7 +51,7 @@ export default function propJsunit() { ...@@ -51,7 +51,7 @@ export default function propJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Prop after each called"); console.info("Prop after each called");
}); });
...@@ -68,8 +68,8 @@ export default function propJsunit() { ...@@ -68,8 +68,8 @@ export default function propJsunit() {
let obj = JSON.parse(strJson); let obj = JSON.parse(strJson);
expect(obj.$type).assertEqual('Text'); expect(obj.$type).assertEqual('Text');
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
console.log("cd attrs.conten type1"+typeof("10")) console.log("cd attrs.conten type1" + typeof ("10"))
console.log("yr prop0 content-'10'"+obj.$attrs.content) console.log("yr prop0 content-'10'" + obj.$attrs.content)
expect(obj.$attrs.content).assertEqual("10"); expect(obj.$attrs.content).assertEqual("10");
console.info('propTest001 END'); console.info('propTest001 END');
done(); done();
...@@ -85,10 +85,10 @@ export default function propJsunit() { ...@@ -85,10 +85,10 @@ export default function propJsunit() {
let strJson = getInspectorByKey('Text002'); let strJson = getInspectorByKey('Text002');
let obj = JSON.parse(strJson); let obj = JSON.parse(strJson);
console.info("component obj is: " + JSON.stringify(obj)); console.info("component obj is: " + JSON.stringify(obj));
console.log("cd attrs.conten type"+typeof(obj.$attrs.content)) console.log("cd attrs.conten type" + typeof (obj.$attrs.content))
console.log("cd attrs.conten type1 "+typeof("10")) console.log("cd attrs.conten type1 " + typeof ("10"))
expect(obj.$attrs.content).assertEqual("10"); expect(obj.$attrs.content).assertEqual("10");
console.log("cd prop0 content-'10'"+JSON.stringify(obj.$attrs.content)) console.log("cd prop0 content-'10'" + JSON.stringify(obj.$attrs.content))
console.info('propTest002 END'); console.info('propTest002 END');
done(); done();
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -28,16 +28,17 @@ export default function rowJsunit() { ...@@ -28,16 +28,17 @@ export default function rowJsunit() {
console.info(`sleep ${time} over...`) console.info(`sleep ${time} over...`)
}) })
} }
describe('rowTest', function () { describe('rowTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Row', uri: 'pages/Row',
} }
try { try {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Row state success " + JSON.stringify(pages)); console.info("get Row state success " + JSON.stringify(pages));
if(!("Row" == pages.name)){ if (!("Row" == pages.name)) {
console.info("get Row state success " + JSON.stringify(pages.name)); console.info("get Row state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Row page success " + JSON.stringify(result)); console.info("push Row page success " + JSON.stringify(result));
...@@ -49,7 +50,7 @@ export default function rowJsunit() { ...@@ -49,7 +50,7 @@ export default function rowJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Row after each called"); console.info("Row after each called");
}); });
...@@ -67,9 +68,9 @@ export default function rowJsunit() { ...@@ -67,9 +68,9 @@ export default function rowJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Row') expect(obj.$type).assertEqual('Row')
console.log('Row‘s useAlign is '+JSON.stringify(obj.$attrs.useAlign)) console.log('Row‘s useAlign is ' + JSON.stringify(obj.$attrs.useAlign))
console.log('Row‘s space is '+JSON.stringify(obj.$attrs.space)) console.log('Row‘s space is ' + JSON.stringify(obj.$attrs.space))
console.log('Row‘s alignItems is '+JSON.stringify(obj.$attrs.alignItems)) console.log('Row‘s alignItems is ' + JSON.stringify(obj.$attrs.alignItems))
expect(obj.$attrs.alignItems).assertEqual('VerticalAlign.Top') expect(obj.$attrs.alignItems).assertEqual('VerticalAlign.Top')
console.info('++++++++++++++++ Row TestCase 1 End ++++++++++++++++'); console.info('++++++++++++++++ Row TestCase 1 End ++++++++++++++++');
done(); done();
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -54,7 +54,7 @@ export default function swiperJsunit() { ...@@ -54,7 +54,7 @@ export default function swiperJsunit() {
describe('swiperTest', function () { describe('swiperTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Swiper', uri: 'pages/Swiper',
} }
...@@ -62,7 +62,7 @@ export default function swiperJsunit() { ...@@ -62,7 +62,7 @@ export default function swiperJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Swiper state success " + JSON.stringify(pages)); console.info("get Swiper state success " + JSON.stringify(pages));
if(!("Swiper" == pages.name)){ if (!("Swiper" == pages.name)) {
console.info("get Swiper state success " + JSON.stringify(pages.name)); console.info("get Swiper state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Swiper page success " + JSON.stringify(result)); console.info("push Swiper page success " + JSON.stringify(result));
...@@ -74,7 +74,7 @@ export default function swiperJsunit() { ...@@ -74,7 +74,7 @@ export default function swiperJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Swiper after each called"); console.info("Swiper after each called");
}); });
...@@ -92,14 +92,14 @@ export default function swiperJsunit() { ...@@ -92,14 +92,14 @@ export default function swiperJsunit() {
console.info("get inspector value is: " + JSON.stringify(obj)); console.info("get inspector value is: " + JSON.stringify(obj));
console.log(JSON.stringify(obj.$type)) console.log(JSON.stringify(obj.$type))
expect(obj.$type).assertEqual('Swiper') expect(obj.$type).assertEqual('Swiper')
console.log('Swiper‘s index is '+JSON.stringify(obj.$attrs.index)) console.log('Swiper‘s index is ' + JSON.stringify(obj.$attrs.index))
console.log('Swiper‘s autoPlay is '+JSON.stringify(obj.$attrs.autoPlay)) console.log('Swiper‘s autoPlay is ' + JSON.stringify(obj.$attrs.autoPlay))
console.log('Swiper‘s interval is '+JSON.stringify(obj.$attrs.interval)) console.log('Swiper‘s interval is ' + JSON.stringify(obj.$attrs.interval))
console.log('Swiper‘s indicator is '+JSON.stringify(obj.$attrs.indicator)) console.log('Swiper‘s indicator is ' + JSON.stringify(obj.$attrs.indicator))
console.log('Swiper‘s loop is '+JSON.stringify(obj.$attrs.loop)) console.log('Swiper‘s loop is ' + JSON.stringify(obj.$attrs.loop))
console.log('Swiper‘s duration is '+JSON.stringify(obj.$attrs.duration)) console.log('Swiper‘s duration is ' + JSON.stringify(obj.$attrs.duration))
console.log('Swiper‘s vertical is '+JSON.stringify(obj.$attrs.vertical)) console.log('Swiper‘s vertical is ' + JSON.stringify(obj.$attrs.vertical))
console.log('Swiper‘s itemSpace is '+JSON.stringify(obj.$attrs.itemSpace)) console.log('Swiper‘s itemSpace is ' + JSON.stringify(obj.$attrs.itemSpace))
expect(obj.$attrs.index).assertEqual('1') expect(obj.$attrs.index).assertEqual('1')
expect(obj.$attrs.autoPlay).assertEqual('true') expect(obj.$attrs.autoPlay).assertEqual('true')
expect(obj.$attrs.interval).assertEqual('4000') expect(obj.$attrs.interval).assertEqual('4000')
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -31,7 +31,7 @@ export default function tabJsunit() { ...@@ -31,7 +31,7 @@ export default function tabJsunit() {
describe('tabTest', function () { describe('tabTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Tab', uri: 'pages/Tab',
} }
...@@ -39,7 +39,7 @@ export default function tabJsunit() { ...@@ -39,7 +39,7 @@ export default function tabJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Tab state success " + JSON.stringify(pages)); console.info("get Tab state success " + JSON.stringify(pages));
if(!("Tab" == pages.name)){ if (!("Tab" == pages.name)) {
console.info("get Tab state success " + JSON.stringify(pages.name)); console.info("get Tab state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Tab page success " + JSON.stringify(result)); console.info("push Tab page success " + JSON.stringify(result));
...@@ -51,7 +51,7 @@ export default function tabJsunit() { ...@@ -51,7 +51,7 @@ export default function tabJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
await sleep(1) await sleep(1)
console.info("Tab after each called"); console.info("Tab after each called");
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -31,7 +31,7 @@ export default function textJsunit() { ...@@ -31,7 +31,7 @@ export default function textJsunit() {
describe('textTest', function () { describe('textTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Text', uri: 'pages/Text',
} }
...@@ -39,7 +39,7 @@ export default function textJsunit() { ...@@ -39,7 +39,7 @@ export default function textJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Text state success " + JSON.stringify(pages)); console.info("get Text state success " + JSON.stringify(pages));
if(!("Text" == pages.name)){ if (!("Text" == pages.name)) {
console.info("get Text state success " + JSON.stringify(pages.name)); console.info("get Text state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Text page success " + JSON.stringify(result)); console.info("push Text page success " + JSON.stringify(result));
...@@ -51,7 +51,7 @@ export default function textJsunit() { ...@@ -51,7 +51,7 @@ export default function textJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
console.info("Text after each called") console.info("Text after each called")
await sleep(1) await sleep(1)
}); });
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
// @ts-nocheck // @ts-nocheck
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets" import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "deccjsunit/index.ets"
import router from '@system.router'; import router from '@system.router';
...@@ -28,9 +28,10 @@ export default function videoJsunit() { ...@@ -28,9 +28,10 @@ export default function videoJsunit() {
console.info(`sleep ${time} over...`) console.info(`sleep ${time} over...`)
}) })
} }
describe('VideoAppInfoTest', function () { describe('VideoAppInfoTest', function () {
beforeEach(async function(done){ beforeEach(async function (done) {
let options = { let options = {
uri: 'pages/Video', uri: 'pages/Video',
} }
...@@ -38,7 +39,7 @@ export default function videoJsunit() { ...@@ -38,7 +39,7 @@ export default function videoJsunit() {
router.clear(); router.clear();
let pages = router.getState(); let pages = router.getState();
console.info("get Video state success " + JSON.stringify(pages)); console.info("get Video state success " + JSON.stringify(pages));
if(!("Video" == pages.name)){ if (!("Video" == pages.name)) {
console.info("get Video state success " + JSON.stringify(pages.name)); console.info("get Video state success " + JSON.stringify(pages.name));
let result = await router.push(options) let result = await router.push(options)
console.info("push Video page success " + JSON.stringify(result)); console.info("push Video page success " + JSON.stringify(result));
...@@ -50,7 +51,7 @@ export default function videoJsunit() { ...@@ -50,7 +51,7 @@ export default function videoJsunit() {
done() done()
}); });
afterEach(async function{ afterEach(async function () {
console.info("Video after each called"); console.info("Video after each called");
await sleep(1) await sleep(1)
}); });
...@@ -66,12 +67,12 @@ export default function videoJsunit() { ...@@ -66,12 +67,12 @@ export default function videoJsunit() {
let strJson = getInspectorByKey('video'); let strJson = getInspectorByKey('video');
let obj = JSON.parse(strJson); let obj = JSON.parse(strJson);
console.info("cd video component obj is: " + JSON.stringify(obj)); console.info("cd video component obj is: " + JSON.stringify(obj));
console.log("cd video type" +JSON.stringify(obj.$type)); console.log("cd video type" + JSON.stringify(obj.$type));
console.log("cd video autoPlay" +JSON.stringify(obj.$attrs.autoPlay)); console.log("cd video autoPlay" + JSON.stringify(obj.$attrs.autoPlay));
console.log("cd video muted" +JSON.stringify(obj.$attrs.muted)); console.log("cd video muted" + JSON.stringify(obj.$attrs.muted));
console.log("cd video controls" +JSON.stringify(obj.$attrs.controls)); console.log("cd video controls" + JSON.stringify(obj.$attrs.controls));
console.log("cd video loop" +JSON.stringify(obj.$attrs.loop)); console.log("cd video loop" + JSON.stringify(obj.$attrs.loop));
console.log("cd video objectFit" +JSON.stringify(obj.$attrs.objectFit)); console.log("cd video objectFit" + JSON.stringify(obj.$attrs.objectFit));
console.info('videoAppInfoTest001 END'); console.info('videoAppInfoTest001 END');
done(); done();
}); });
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册