提交 2b203fd5 编写于 作者: 雪洛's avatar 雪洛

feat: update uniCloud test case

上级 6b1c671f
......@@ -10,17 +10,17 @@ describe('unicloud-database', () => {
await page.callMethod('dbRemove')
await page.waitFor(3000)
await page.callMethod('dbAdd')
await page.waitFor(1000)
await page.waitFor(2000)
await page.callMethod('dbBatchAdd')
await page.waitFor(1000)
await page.waitFor(2000)
await page.callMethod('dbGet')
await page.waitFor(1000)
await page.waitFor(2000)
await page.callMethod('dbGetWithCommand')
await page.waitFor(1000)
await page.waitFor(2000)
await page.callMethod('dbUpdate')
await page.waitFor(1000)
await page.waitFor(2000)
await page.callMethod('dbRemove')
await page.waitFor(1000)
await page.waitFor(2000)
const {
addId,
......@@ -32,6 +32,8 @@ describe('unicloud-database', () => {
removeDeleted,
} = await page.data()
console.error((await page.data()).batchAddinserted)
expect(addId.length > 0).toBe(true)
expect(batchAddIds.length).toBe(2)
expect(batchAddinserted).toBe(2)
......@@ -44,9 +46,9 @@ describe('unicloud-database', () => {
it('databaseLookup', async () => {
await page.callMethod('dbLookupInit')
await page.waitFor(1000)
await page.waitFor(3000)
await page.callMethod('dbLookup')
await page.waitFor(1000)
await page.waitFor(2000)
const {
lookupData
......
......@@ -91,7 +91,7 @@
this.batchAddIds = res.ids
this.batchAddinserted = res.inserted
uni.showModal({
content: `新增成功id列表: ${res.ids.join(',')}`,
content: `新增成功条数${res.inserted}, id列表: ${res.ids.join(',')}`,
showCancel: false
})
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册