修复(半自动履约): 虎牙绑定仅核验角色名与区服
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/** 只有平台独立返回的纯数字游戏角色 UID 才能作为自动核验依据。 */
|
||||
/** 判断平台是否独立返回了纯数字游戏角色 UID;该值只作可选留档,不参与绑定核验。 */
|
||||
export function isNumericBindingRoleId(value: unknown): boolean {
|
||||
return /^\d+$/.test(String(value ?? '').trim())
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ import test from 'node:test'
|
||||
|
||||
import {
|
||||
classifyHuyaRebindFailure,
|
||||
compareHuyaBindingRole,
|
||||
resolveHuyaBindingDecision,
|
||||
resolveHuyaRoleRebindAvailability,
|
||||
roleSnapshotsFromLegacyFields,
|
||||
@@ -90,6 +91,25 @@ test('已有角色且就是目标角色时直接确认当前角色', () => {
|
||||
assert.equal(decision.primaryAction, 'confirm_current_role')
|
||||
})
|
||||
|
||||
test('平台数值角色 UID 与客户填写值不同,也不阻断角色名区服核验', () => {
|
||||
const decision = resolveHuyaBindingDecision(
|
||||
input({
|
||||
current: role({
|
||||
roleName: TARGET.roleName,
|
||||
platformRoleUid: '99887766',
|
||||
}),
|
||||
bindingStatus: 'role_ready',
|
||||
}),
|
||||
)
|
||||
assert.equal(decision.targetRoleMatch, 'match')
|
||||
assert.equal(decision.flowState, 'current_role_confirmable')
|
||||
assert.equal(decision.comparison.verificationBasis, 'role_name_zone')
|
||||
|
||||
const direct = compareHuyaBindingRole(TARGET, role({ roleName: TARGET.roleName }))
|
||||
assert.equal(direct.verdict, 'match')
|
||||
assert.equal(direct.verificationBasis, 'role_name_zone')
|
||||
})
|
||||
|
||||
test('平台原始状态为 confirmed 时仍以唯一决策器的目标匹配结果为准', () => {
|
||||
const matched = resolveHuyaBindingDecision(
|
||||
input({
|
||||
|
||||
@@ -146,31 +146,30 @@ function comparisonBase(customer: HuyaCustomerRoleSnapshot, role: HuyaRoleSnapsh
|
||||
const roleName = readString(role?.roleName)
|
||||
const roleToken = readString(role?.roleToken)
|
||||
const platformRoleUid = readString(role?.platformRoleUid)
|
||||
const numericPlatformRoleUid = isNumericBindingRoleId(platformRoleUid) ? platformRoleUid : ''
|
||||
const boundZone = resolveServerZone(role?.channel)
|
||||
return {
|
||||
customerRoleName,
|
||||
customerRoleId,
|
||||
customerZone,
|
||||
boundRoleName: roleName,
|
||||
boundRoleId: platformRoleUid || roleToken,
|
||||
boundRoleIdKind: platformRoleUid
|
||||
boundRoleId: numericPlatformRoleUid || roleToken,
|
||||
boundRoleIdKind: numericPlatformRoleUid
|
||||
? ('game_role_uid' as const)
|
||||
: isHuyaRoleToken(roleToken)
|
||||
? ('huya_role_token' as const)
|
||||
: ('missing' as const),
|
||||
boundZone,
|
||||
verificationBasis: platformRoleUid
|
||||
? ('platform_numeric_uid' as const)
|
||||
: ('role_name_zone' as const),
|
||||
platformRoleUid,
|
||||
verificationBasis: 'role_name_zone' as const,
|
||||
platformRoleUid: numericPlatformRoleUid,
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 虎牙角色比对的唯一入口。
|
||||
*
|
||||
* 当前虎牙只稳定返回角色名、区服和可选的数值平台角色 UID。
|
||||
* 40 位加密 role token 只用于判断平台前后角色是否变化,不参与客户资料比对。
|
||||
* 绑定放行固定只比较角色名和平台区服。可选的数值平台角色 UID 仅用于展示和留档;
|
||||
* 40 位加密 role token 只用于判断平台前后角色是否变化,二者都不参与客户资料放行。
|
||||
*/
|
||||
export function compareHuyaBindingRole(
|
||||
customer: HuyaCustomerRoleSnapshot,
|
||||
@@ -179,9 +178,7 @@ export function compareHuyaBindingRole(
|
||||
const base = comparisonBase(customer, role)
|
||||
const policy = getAccountBindingPolicy('huya')
|
||||
const comparison = compareBindingIdentity({
|
||||
requiredFields: base.platformRoleUid
|
||||
? [...policy.requiredFields, 'roleId']
|
||||
: policy.requiredFields,
|
||||
requiredFields: policy.requiredFields,
|
||||
customer: {
|
||||
roleName: base.customerRoleName,
|
||||
roleId: base.customerRoleId,
|
||||
@@ -205,19 +202,15 @@ export function compareHuyaBindingRole(
|
||||
}
|
||||
}
|
||||
if (comparison.verdict === 'mismatch') {
|
||||
const message = comparison.mismatched.includes('roleId')
|
||||
? '两侧游戏角色 UID 不一致,无法提交平台绑定'
|
||||
: comparison.mismatched.includes('roleName')
|
||||
? '两侧角色名称不一致,无法提交平台绑定'
|
||||
: '两侧区服不一致,无法提交平台绑定'
|
||||
const message = comparison.mismatched.includes('roleName')
|
||||
? '两侧角色名称不一致,无法提交平台绑定'
|
||||
: '两侧区服不一致,无法提交平台绑定'
|
||||
return { ...base, verdict: 'mismatch', message, missing, mismatched }
|
||||
}
|
||||
return {
|
||||
...base,
|
||||
verdict: 'match',
|
||||
message: base.platformRoleUid
|
||||
? '两侧区服、角色名称、平台角色 UID 一致,可提交平台绑定'
|
||||
: '角色名称与区服一致,请确认绑定本次待确认角色',
|
||||
message: '角色名称与区服一致,请确认绑定本次待确认角色',
|
||||
missing,
|
||||
mismatched,
|
||||
}
|
||||
|
||||
@@ -1749,11 +1749,7 @@ export class HuyaNativeConnector {
|
||||
: binding.role
|
||||
? 'huya_outer_current'
|
||||
: '',
|
||||
verificationBasis: binding.roleUid
|
||||
? 'platform_numeric_uid'
|
||||
: binding.role
|
||||
? 'role_name_zone'
|
||||
: '',
|
||||
verificationBasis: binding.role || binding.pendingRole ? 'role_name_zone' : '',
|
||||
roleIdVerified,
|
||||
requiresSupport,
|
||||
hasExistingBinding: binding.hasExistingBinding,
|
||||
|
||||
@@ -5,6 +5,7 @@ import { isHuyaRoleToken, isNumericBindingRoleId } from './binding-role-id.js'
|
||||
import {
|
||||
compareBindingRole,
|
||||
detectServerZone,
|
||||
hasCustomerProfile,
|
||||
normalizeCustomerProfile,
|
||||
} from './semi-auto-task-service.js'
|
||||
|
||||
@@ -116,7 +117,7 @@ describe('虎牙角色比对', () => {
|
||||
assert.match(missingZone.message, /客户区服/)
|
||||
})
|
||||
|
||||
it('平台明确返回数值角色 UID 时才启用数值核验', () => {
|
||||
it('平台返回数值角色 UID 时仍只按角色名与区服核验', () => {
|
||||
const result = compareBindingRole(task('落地盒子怪cc', '4212063544', '安卓Q区'), {
|
||||
bindGameRole: '落地盒子怪cc',
|
||||
bindGameRoleToken: HUYA_ROLE_TOKEN,
|
||||
@@ -125,22 +126,43 @@ describe('虎牙角色比对', () => {
|
||||
})
|
||||
assert.equal(result.verdict, 'match')
|
||||
assert.equal(result.boundRoleIdKind, 'game_role_uid')
|
||||
assert.equal(result.verificationBasis, 'platform_numeric_uid')
|
||||
assert.equal(result.verificationBasis, 'role_name_zone')
|
||||
})
|
||||
|
||||
it('平台未来返回数值角色 UID 时,数值不同也不能确认', () => {
|
||||
it('平台返回数值角色 UID 且与客户填写值不同,仍按角色名区服放行', () => {
|
||||
const result = compareBindingRole(task('落地盒子怪cc', '4212063544', '安卓Q区'), {
|
||||
bindGameRole: '落地盒子怪cc',
|
||||
bindGameRoleToken: HUYA_ROLE_TOKEN,
|
||||
bindGameChannel: '安卓(android) · QQ',
|
||||
platformGameRoleUid: '4212063545',
|
||||
})
|
||||
assert.equal(result.verdict, 'mismatch')
|
||||
assert.match(result.message, /游戏角色 UID/)
|
||||
assert.equal(result.verdict, 'match')
|
||||
assert.equal(result.verificationBasis, 'role_name_zone')
|
||||
assert.match(result.message, /角色名称与区服一致/)
|
||||
})
|
||||
})
|
||||
|
||||
describe('客户角色资料校验', () => {
|
||||
it('角色名和区服齐全时,游戏角色 UID 可以留空', () => {
|
||||
const profile = normalizeCustomerProfile({
|
||||
roleName: '落地盒子怪cc',
|
||||
roleId: '',
|
||||
serverZone: '安卓Q区',
|
||||
})
|
||||
assert.deepEqual(profile, {
|
||||
roleName: '落地盒子怪cc',
|
||||
roleId: '',
|
||||
serverZone: '安卓Q区',
|
||||
})
|
||||
assert.equal(
|
||||
hasCustomerProfile({
|
||||
customer_game_role: '落地盒子怪cc',
|
||||
customer_server_zone: '安卓Q区',
|
||||
}),
|
||||
true,
|
||||
)
|
||||
})
|
||||
|
||||
it('清理空白并保留纯数字游戏角色 UID', () => {
|
||||
const profile = normalizeCustomerProfile({
|
||||
roleName: ' 落地盒子怪cc ',
|
||||
@@ -168,10 +190,10 @@ describe('客户角色资料校验', () => {
|
||||
)
|
||||
})
|
||||
|
||||
it('角色名称与游戏角色 UID 都为空时拒绝保存', () => {
|
||||
it('角色名称为空时拒绝保存', () => {
|
||||
assert.throws(
|
||||
() => normalizeCustomerProfile({ roleName: ' ', roleId: '', serverZone: '安卓Q区' }),
|
||||
/请完整填写区服/,
|
||||
/请完整填写区服和角色名/,
|
||||
)
|
||||
})
|
||||
})
|
||||
|
||||
@@ -123,8 +123,8 @@ export function normalizeCustomerProfile(input: CustomerProfileInput = {}) {
|
||||
errorCode: 'semi_auto_profile_server_zone_invalid',
|
||||
})
|
||||
}
|
||||
if (!roleName || !roleId) {
|
||||
throw createHttpError('请完整填写区服、游戏角色 UID 和角色名', {
|
||||
if (!roleName || !serverZone) {
|
||||
throw createHttpError('请完整填写区服和角色名', {
|
||||
statusCode: 400,
|
||||
errorCode: 'semi_auto_profile_required',
|
||||
})
|
||||
@@ -134,7 +134,7 @@ export function normalizeCustomerProfile(input: CustomerProfileInput = {}) {
|
||||
|
||||
/**
|
||||
* 半自动订单没有 work_orders,客户资料在授权页 /c/<订单号>(虎牙)或 /d/<订单号>(微博)收集。
|
||||
* 虎牙先保存目标角色资料,再登录账号;保存后立即参与平台角色比对。
|
||||
* 虎牙先保存目标角色名和区服,再登录账号;游戏角色 UID 可选留档,不参与绑定核验。
|
||||
*/
|
||||
export async function savePublicTaskProfile(
|
||||
orderNoInput: unknown,
|
||||
|
||||
@@ -257,12 +257,10 @@ export function normalizeOrderNo(value: unknown): string {
|
||||
|
||||
/** 客户资料以 TASK_SELECT 合并后的字段为准:优先任务表,回退工单资料。 */
|
||||
export function hasCustomerProfile(
|
||||
task: Pick<TaskRow, 'customer_game_id' | 'customer_game_role' | 'customer_server_zone'>,
|
||||
task: Pick<TaskRow, 'customer_game_role' | 'customer_server_zone'>,
|
||||
): boolean {
|
||||
return Boolean(
|
||||
String(task.customer_game_id || '').trim() &&
|
||||
String(task.customer_game_role || '').trim() &&
|
||||
String(task.customer_server_zone || '').trim(),
|
||||
String(task.customer_game_role || '').trim() && String(task.customer_server_zone || '').trim(),
|
||||
)
|
||||
}
|
||||
|
||||
@@ -433,12 +431,7 @@ export function displayStatus(task: TaskRow, decision = resolveTaskHuyaBindingDe
|
||||
return status('processing', '处理中', 'operator', '客服继续履约')
|
||||
}
|
||||
if (bindingPolicy.requiresCustomerProfile && !hasCustomerProfile(task)) {
|
||||
return status(
|
||||
'waiting_profile',
|
||||
'待客户填写资料',
|
||||
'customer',
|
||||
'客户填写区服、游戏角色 UID 和角色名',
|
||||
)
|
||||
return status('waiting_profile', '待客户填写资料', 'customer', '客户填写区服和角色名')
|
||||
}
|
||||
if (task.login_status === 'authenticated') {
|
||||
if (task.platform === 'huya' && decision) {
|
||||
@@ -754,7 +747,7 @@ export function assertHuyaTask(task: TaskRow) {
|
||||
/**
|
||||
* 半自动订单没有工单时,客户资料在登录后由 /c/<订单号> 收集;
|
||||
* 任务表为空但工单素材已有资料时,TASK_SELECT 会合并回退字段。
|
||||
* 进入绑定/确认/换绑前必须已有完整三项资料。
|
||||
* 进入绑定/确认/换绑前必须已有角色名和区服;游戏角色 UID 可选。
|
||||
*/
|
||||
export function assertCustomerProfileReady(task: TaskRow) {
|
||||
if (!getAccountBindingPolicy(task.platform).requiresCustomerProfile) return
|
||||
@@ -1354,9 +1347,8 @@ export function detectServerZone(channel: unknown): string {
|
||||
}
|
||||
|
||||
/**
|
||||
* 虎牙账号 UID 与游戏角色 UID 无关。当前虎牙接口只稳定返回角色名、区服和
|
||||
* opaque role token,因此自动放行依据固定为角色名 + 区服。客户角色 UID
|
||||
* 只作为订单资料留档,除非平台明确返回独立数值角色 UID,否则不参与比对。
|
||||
* 虎牙账号 UID 与游戏角色 UID 无关。自动放行依据固定为角色名 + 平台区服;
|
||||
* 客户角色 UID 和平台可能返回的数值角色 UID 都只作可选留档,不参与比对。
|
||||
*/
|
||||
export function compareBindingRole(
|
||||
task: Pick<TaskRow, 'customer_game_id' | 'customer_game_role' | 'customer_game_server_zone'>,
|
||||
|
||||
@@ -1396,9 +1396,9 @@ test(
|
||||
|
||||
const saved = await savePublicTaskProfile(orderNo, result.taskId, {
|
||||
roleName: 'Mock虎牙角色',
|
||||
roleId: '1192083858',
|
||||
serverZone: '安卓V区',
|
||||
})
|
||||
assert.equal(saved.task.customerGameRoleId, '')
|
||||
assert.equal(saved.task.loginStatus, 'waiting_login')
|
||||
assert.equal(saved.task.displayStatus.label, '等待客户授权')
|
||||
|
||||
@@ -1427,7 +1427,7 @@ test(
|
||||
assert.equal(tasks[0]?.executionStatus, 'waiting_customer')
|
||||
assert.equal(tasks[0]?.displayStatus.label, '等待客户绑定角色')
|
||||
assert.equal(tasks[0]?.customerGameRoleName, 'Mock虎牙角色')
|
||||
assert.equal(tasks[0]?.customerGameRoleId, '1192083858')
|
||||
assert.equal(tasks[0]?.customerGameRoleId, '')
|
||||
assert.equal(tasks[0]?.credentialSource, 'sms')
|
||||
assert.ok(tasks[0]?.huyaUid)
|
||||
assert.equal(tasks[0]?.platformNickname, 'Mock虎牙用户')
|
||||
|
||||
@@ -849,9 +849,7 @@ export default function AdminSemiAutoTasksPage() {
|
||||
}
|
||||
>
|
||||
{detail.comparison?.verdict === 'match'
|
||||
? detail.comparison.verificationBasis === 'platform_numeric_uid'
|
||||
? '角色名、区服和平台角色 UID 一致,可提交平台绑定'
|
||||
: '角色名与区服一致,可提交平台绑定'
|
||||
? '角色名与区服一致,可提交平台绑定'
|
||||
: detail.comparison?.verdict === 'mismatch'
|
||||
? '资料与平台角色不一致'
|
||||
: '信息不完整,需人工核实'}
|
||||
|
||||
@@ -116,11 +116,10 @@ export default function CustomerFulfillmentPage({
|
||||
),
|
||||
)
|
||||
const isWeibo = selectedTask?.platform === 'weibo'
|
||||
// 虎牙流程:填写资料(区服/游戏角色 UID/角色名)→ 登录 → 绑定角色。
|
||||
// 虎牙流程:填写资料(区服/角色名,UID 可选)→ 登录 → 绑定角色。
|
||||
// 资料齐全前不生成绑定二维码,避免客户在资料缺失时先绑错角色。
|
||||
const profileComplete = Boolean(
|
||||
String(selectedTask?.customerServerZone || '').trim() &&
|
||||
String(selectedTask?.customerGameRoleId || '').trim() &&
|
||||
String(selectedTask?.customerGameRoleName || '').trim(),
|
||||
)
|
||||
|
||||
@@ -931,15 +930,15 @@ export default function CustomerFulfillmentPage({
|
||||
|
||||
async function handleSaveProfile() {
|
||||
if (!selectedTask) return
|
||||
if (!profileServerZone.trim() || !profileRoleId.trim() || !profileRoleName.trim()) {
|
||||
message.warning('请完整填写区服、游戏角色 UID 和角色名')
|
||||
if (!profileServerZone.trim() || !profileRoleName.trim()) {
|
||||
message.warning('请完整填写区服和角色名')
|
||||
return
|
||||
}
|
||||
if (!SERVER_ZONE_OPTIONS.includes(profileServerZone.trim())) {
|
||||
message.warning('请选择区服')
|
||||
return
|
||||
}
|
||||
if (!/^\d+$/.test(profileRoleId.trim())) {
|
||||
if (profileRoleId.trim() && !/^\d+$/.test(profileRoleId.trim())) {
|
||||
message.warning('游戏角色 UID 只能是数字')
|
||||
return
|
||||
}
|
||||
@@ -1221,7 +1220,7 @@ export default function CustomerFulfillmentPage({
|
||||
<p>
|
||||
{profileComplete
|
||||
? '修改目标角色资料后会重新核对虎牙账号当前绑定角色;角色名与区服一致后才能确认绑定。'
|
||||
: '第一步:请填写区服、游戏角色 UID 和角色名。游戏角色 UID 与稍后登录的虎牙账号 UID 不是同一个编号。'}
|
||||
: '第一步:请填写区服和角色名。游戏角色 UID 为选填资料,不参与绑定核验。'}
|
||||
</p>
|
||||
<div className="customer-profile-form">
|
||||
<label className="customer-collect-label">
|
||||
@@ -1235,14 +1234,12 @@ export default function CustomerFulfillmentPage({
|
||||
placeholder="请选择区服"
|
||||
options={SERVER_ZONE_OPTIONS.map((value) => ({ value, label: value }))}
|
||||
/>
|
||||
<label className="customer-collect-label">
|
||||
游戏角色 UID <span>*</span>
|
||||
</label>
|
||||
<label className="customer-collect-label">游戏角色 UID(选填)</label>
|
||||
<Input
|
||||
className="customer-collect-input"
|
||||
value={profileRoleId}
|
||||
onChange={(event) => setProfileRoleId(event.target.value)}
|
||||
placeholder="请输入游戏角色 UID"
|
||||
placeholder="选填,仅用于订单资料留档"
|
||||
maxLength={64}
|
||||
inputMode="numeric"
|
||||
/>
|
||||
@@ -1590,7 +1587,7 @@ export default function CustomerFulfillmentPage({
|
||||
<strong>{currentRoleName || '未识别到角色'}</strong>
|
||||
</div>
|
||||
<div>
|
||||
<span>目标角色 UID</span>
|
||||
<span>目标角色 UID(选填)</span>
|
||||
<strong>{targetRoleUid || '未填写'}</strong>
|
||||
</div>
|
||||
{pendingRoleName ? (
|
||||
@@ -1669,7 +1666,7 @@ export default function CustomerFulfillmentPage({
|
||||
: '请使用微信APP扫码进行游戏角色绑定'}
|
||||
</p>
|
||||
<p className="customer-binding-qr-hint">
|
||||
扫码后系统会核对待确认角色的名称与区服,不会用虎牙账号 UID 代替游戏角色 UID。
|
||||
扫码后系统只核对角色名称与区服,UID 不参与绑定判定。
|
||||
</p>
|
||||
<p className="customer-binding-qr-tip">
|
||||
{selectedTask?.bindingStatus === 'scanned'
|
||||
@@ -2008,7 +2005,7 @@ export default function CustomerFulfillmentPage({
|
||||
>
|
||||
<Space direction="vertical" size={14} style={{ width: '100%' }}>
|
||||
<p style={{ margin: 0 }}>
|
||||
请核对角色名称与区服。游戏角色 UID 单独留档,不会与虎牙登录账号 UID 比对。
|
||||
请核对角色名称与区服。游戏角色 UID 为选填留档,不参与绑定判定。
|
||||
</p>
|
||||
<div className="customer-binding-compare">
|
||||
<div className="customer-binding-compare-side">
|
||||
@@ -2019,7 +2016,7 @@ export default function CustomerFulfillmentPage({
|
||||
</Button>
|
||||
</div>
|
||||
<strong>{bindingComparison?.customerRoleName || '未填写'}</strong>
|
||||
<em>{bindingComparison?.customerRoleId || '未填写游戏角色 UID'}</em>
|
||||
<em>{bindingComparison?.customerRoleId || '未填写游戏角色 UID(不影响绑定)'}</em>
|
||||
</div>
|
||||
<div className="customer-binding-compare-side">
|
||||
<div className="customer-binding-compare-head">
|
||||
|
||||
@@ -50,6 +50,19 @@ test('虎牙客户页固定先填写资料,再登录并绑定角色', () => {
|
||||
assert.ok(source.includes('(isWeibo || profileComplete) &&'))
|
||||
})
|
||||
|
||||
test('资料完整只要求区服和角色名,游戏角色 UID 可选', () => {
|
||||
const profileStart = source.indexOf('const profileComplete = Boolean(')
|
||||
const profileEnd = source.indexOf('\n\n const load =', profileStart)
|
||||
const profileSource = source.slice(profileStart, profileEnd)
|
||||
assert.ok(profileSource.includes('customerServerZone'))
|
||||
assert.ok(profileSource.includes('customerGameRoleName'))
|
||||
assert.ok(!profileSource.includes('customerGameRoleId'))
|
||||
assert.ok(source.includes('请完整填写区服和角色名'))
|
||||
assert.ok(source.includes('游戏角色 UID 为选填资料,不参与绑定核验'))
|
||||
assert.ok(source.includes('游戏角色 UID(选填)'))
|
||||
assert.ok(source.includes('if (profileRoleId.trim() && !/^\\d+$/.test(profileRoleId.trim()))'))
|
||||
})
|
||||
|
||||
test('登录和绑定专用同步阶段暂停整单轮询', () => {
|
||||
assert.ok(source.includes('const dedicatedLoginPoll ='))
|
||||
assert.ok(source.includes('const dedicatedBindingPoll ='))
|
||||
@@ -74,10 +87,9 @@ test('角色名和区服一致才出现确认绑定,不一致时展示原因',
|
||||
assert.ok(source.includes('customer-binding-modal-error'))
|
||||
})
|
||||
|
||||
test('二维码区明确区分虎牙账号 UID 与游戏角色 UID', () => {
|
||||
assert.ok(source.includes('扫码后系统会核对待确认角色的名称与区服'))
|
||||
assert.ok(source.includes('不会用虎牙账号 UID'))
|
||||
assert.ok(source.includes('游戏角色 UID 与稍后登录的虎牙账号 UID 不是同一个编号'))
|
||||
test('二维码区明确只核验角色名与区服,UID 不参与绑定', () => {
|
||||
assert.ok(source.includes('扫码后系统只核对角色名称与区服,UID 不参与绑定判定'))
|
||||
assert.ok(source.includes('游戏角色 UID 为选填留档,不参与绑定判定'))
|
||||
assert.ok(source.includes('本次待确认角色'))
|
||||
assert.ok(source.includes('虎牙账号 UID'))
|
||||
assert.ok(!source.includes('平台已返回加密角色标识'))
|
||||
|
||||
@@ -39,7 +39,7 @@ test('取消直接使用原角色的快捷确认路径', () => {
|
||||
test('点击上一步修改资料会回到第一步并隐藏绑定区', () => {
|
||||
// 步骤条把编辑资料视为第一步,即使资料原本已完整。
|
||||
assert.ok(source.includes('profileEditing || !profileComplete'))
|
||||
assert.ok(source.includes("'第一步:请填写区服、游戏角色 UID 和角色名"))
|
||||
assert.ok(source.includes("'第一步:请填写区服和角色名"))
|
||||
assert.ok(source.includes('返回绑定角色'))
|
||||
// 资料步骤隐藏二维码、失败提示和比对操作,避免与第二步混在一起。
|
||||
assert.ok(source.includes('!profileEditing'))
|
||||
|
||||
@@ -60,10 +60,10 @@ test('换绑冷却明确指向虎牙登录账号', () => {
|
||||
assert.ok(adminPage.includes("rebind_blocked_account: '虎牙账号换绑冷却中'"))
|
||||
})
|
||||
|
||||
test('虎牙默认只声明角色名与区服一致,不把客户角色 UID 冒充已核验', () => {
|
||||
test('虎牙只声明角色名与区服一致,平台角色 UID 不参与核验', () => {
|
||||
assert.ok(!adminPage.includes('三项一致,可提交平台绑定'))
|
||||
assert.ok(adminPage.includes('角色名与区服一致,可提交平台绑定'))
|
||||
assert.ok(adminPage.includes('角色名、区服和平台角色 UID 一致,可提交平台绑定'))
|
||||
assert.ok(!adminPage.includes('角色名、区服和平台角色 UID 一致,可提交平台绑定'))
|
||||
})
|
||||
|
||||
test('后台不再展示虎牙加密角色标识', () => {
|
||||
|
||||
Reference in New Issue
Block a user