支持 khhao 快手双店铺ID匹配
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
import test from 'node:test'
|
||||
import assert from 'node:assert/strict'
|
||||
|
||||
import { resolveBindingMatchShopIds } from './fulfillment-bootstrap-service.js'
|
||||
|
||||
test('resolveBindingMatchShopIds returns dual shop ids for khhao kuaishou bindings', () => {
|
||||
assert.deepEqual(
|
||||
resolveBindingMatchShopIds({
|
||||
provider: 'khhao',
|
||||
platform: 'kuaishou',
|
||||
shopId: '4269276762',
|
||||
khhaoShopId: '10',
|
||||
}),
|
||||
['10', '4269276762'],
|
||||
)
|
||||
})
|
||||
|
||||
test('resolveBindingMatchShopIds preserves wildcard rules for empty shop id', () => {
|
||||
assert.deepEqual(
|
||||
resolveBindingMatchShopIds({
|
||||
provider: 'agiso',
|
||||
platform: 'xianyu',
|
||||
shopId: '',
|
||||
}),
|
||||
[''],
|
||||
)
|
||||
})
|
||||
Reference in New Issue
Block a user