Skip to content

Commit

Permalink
test: fix typo
Browse files Browse the repository at this point in the history
  • Loading branch information
waitingsong committed Jan 25, 2024
1 parent c24cecd commit 9c85879
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
validatePageRetPartial,
validateRet,
validateRowsOrder,
validateRowsOrderPartical,
validateRowsOrderPartial,
} from './util.js'

import { KmoreFactory, PageRawType } from '##/index.js'
Expand Down Expand Up @@ -100,60 +100,60 @@ describe(fileShortPath(import.meta.url), () => {
.select('uid', 'realName')
.orderBy('uid', ord)
validatePageRetPartial(ret30, colkeys)
validateRowsOrderPartical(ret30, ord)
validateRowsOrderPartial(ret30, ord)

const ret31 = await tables.ref_tb_user()
.autoPaging()
.select('uid', 'realName')
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret31, colkeys)
validateRowsOrderPartical(ret31, ord)
validateRowsOrderPartial(ret31, ord)

const ret32 = await tables.ref_tb_user()
.select('uid', 'realName')
.autoPaging()
.orderBy('uid', ord)
validatePageRetPartial(ret32, colkeys)
validateRowsOrderPartical(ret32, ord)
validateRowsOrderPartial(ret32, ord)

const ret33 = await tables.ref_tb_user()
.select('uid', 'realName')
.autoPaging()
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret33, colkeys)
validateRowsOrderPartical(ret33, ord)
validateRowsOrderPartial(ret33, ord)

const ret40 = await tables.ref_tb_user()
.autoPaging()
.select(colkeys)
.orderBy('uid', ord)
validatePageRetPartial(ret40, colkeys)
validateRowsOrderPartical(ret40, ord)
validateRowsOrderPartial(ret40, ord)

const ret41 = await tables.ref_tb_user()
.autoPaging()
.select(colkeys)
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret41, colkeys)
validateRowsOrderPartical(ret41, ord)
validateRowsOrderPartial(ret41, ord)

const ret42 = await tables.ref_tb_user()
.select(colkeys)
.autoPaging()
.orderBy('uid', ord)
validatePageRetPartial(ret42, colkeys)
validateRowsOrderPartical(ret42, ord)
validateRowsOrderPartial(ret42, ord)

const ret43 = await tables.ref_tb_user()
.select(colkeys)
.autoPaging()
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret43, colkeys)
validateRowsOrderPartical(ret43, ord)
validateRowsOrderPartial(ret43, ord)
})

it('where', async () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
validatePageRetPartial,
validateRet,
validateRowsOrder,
validateRowsOrderPartical,
validateRowsOrderPartial,
} from './util.js'

import { KmoreFactory } from '##/index.js'
Expand Down Expand Up @@ -100,60 +100,60 @@ describe(fileShortPath(import.meta.url), () => {
.select('uid', 'realName')
.orderBy('uid', ord)
validatePageRetPartial(ret30, colkeys)
validateRowsOrderPartical(ret30, ord)
validateRowsOrderPartial(ret30, ord)

const ret31 = await tables.ref_tb_user()
.autoPaging()
.select('uid', 'realName')
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret31, colkeys)
validateRowsOrderPartical(ret31, ord)
validateRowsOrderPartial(ret31, ord)

const ret32 = await tables.ref_tb_user()
.select('uid', 'realName')
.autoPaging()
.orderBy('uid', ord)
validatePageRetPartial(ret32, colkeys)
validateRowsOrderPartical(ret32, ord)
validateRowsOrderPartial(ret32, ord)

const ret33 = await tables.ref_tb_user()
.select('uid', 'realName')
.autoPaging()
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret33, colkeys)
validateRowsOrderPartical(ret33, ord)
validateRowsOrderPartial(ret33, ord)

const ret40 = await tables.ref_tb_user()
.autoPaging()
.select(colkeys)
.orderBy('uid', ord)
validatePageRetPartial(ret40, colkeys)
validateRowsOrderPartical(ret40, ord)
validateRowsOrderPartial(ret40, ord)

const ret41 = await tables.ref_tb_user()
.autoPaging()
.select(colkeys)
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret41, colkeys)
validateRowsOrderPartical(ret41, ord)
validateRowsOrderPartial(ret41, ord)

const ret42 = await tables.ref_tb_user()
.select(colkeys)
.autoPaging()
.orderBy('uid', ord)
validatePageRetPartial(ret42, colkeys)
validateRowsOrderPartical(ret42, ord)
validateRowsOrderPartial(ret42, ord)

const ret43 = await tables.ref_tb_user()
.select(colkeys)
.autoPaging()
.orderBy('uid', ord)
.then()
validatePageRetPartial(ret43, colkeys)
validateRowsOrderPartical(ret43, ord)
validateRowsOrderPartial(ret43, ord)
})

it('where', async () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/kmore/test/auto-paging/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ export function validateRowsOrder(input: PageRawType<UserDTO>, ord: 'asc' | 'des

}

export function validateRowsOrderPartical(input: PageRawType<Partial<UserDTO>>, ord: 'asc' | 'desc'): void {
export function validateRowsOrderPartial(input: PageRawType<Partial<UserDTO>>, ord: 'asc' | 'desc'): void {
assert(input)
const len = input.length
assert(len > 1, 'should input.length > 1')
Expand Down

0 comments on commit 9c85879

Please sign in to comment.