feat(expert): create dedicated expert apply page and navigate from user center
这个提交包含在:
@@ -130,7 +130,7 @@ describe('ContentSecurityService & Compliance Architecture (TDD 微信内容安
|
||||
const raw = fs.readFileSync(pagesJsonPath, 'utf-8');
|
||||
const config = JSON.parse(raw);
|
||||
expect(Array.isArray(config.pages)).toBe(true);
|
||||
expect(config.pages.length).toBe(13);
|
||||
expect(config.pages.length).toBe(14);
|
||||
|
||||
for (const pageItem of config.pages) {
|
||||
const vueFilePath = path.join(rootDir, 'pwuniapp', `${pageItem.path}.vue`);
|
||||
@@ -407,5 +407,44 @@ describe('ContentSecurityService & Compliance Architecture (TDD 微信内容安
|
||||
expect(emojiRegex.test(text)).toBe(false);
|
||||
});
|
||||
});
|
||||
|
||||
describe('11. 大神实名认证专属独立页面与多态流程验证 (pages/expert/apply.vue)', () => {
|
||||
it('pages.json 必须成功注册 pages/expert/apply 且物理文件必须存在', () => {
|
||||
const applyPath = path.join(rootDir, 'pwuniapp', 'pages', 'expert', 'apply.vue');
|
||||
expect(fs.existsSync(applyPath)).toBe(true);
|
||||
const pagesJsonPath = path.join(rootDir, 'pwuniapp', 'pages.json');
|
||||
const pagesJson = fs.readFileSync(pagesJsonPath, 'utf-8');
|
||||
expect(pagesJson).toContain('pages/expert/apply');
|
||||
expect(pagesJson).toContain('大神入驻认证');
|
||||
});
|
||||
|
||||
it('大神入驻申请独立页面必须包含完整表单、协议声明与提交接口', () => {
|
||||
const applyPath = path.join(rootDir, 'pwuniapp', 'pages', 'expert', 'apply.vue');
|
||||
const content = fs.readFileSync(applyPath, 'utf-8');
|
||||
expect(content).toContain('applyForm');
|
||||
expect(content).toContain('applyExpertCert');
|
||||
expect(content).toContain('TRACK_OPTIONS');
|
||||
expect(content).toContain('expertPriceMin');
|
||||
expect(content).toContain('expertPriceMax');
|
||||
expect(content).toContain('candidateTags');
|
||||
expect(content).toContain('submitApply');
|
||||
expect(content).toContain('实名认证审核中');
|
||||
expect(content).toContain('已通过大神实名认证');
|
||||
});
|
||||
|
||||
it('个人中心的大神入驻入口必须路由跳转至 /pages/expert/apply', () => {
|
||||
const userIndexPath = path.join(rootDir, 'pwuniapp', 'pages', 'user', 'index.vue');
|
||||
const content = fs.readFileSync(userIndexPath, 'utf-8');
|
||||
expect(content).toContain('/pages/expert/apply');
|
||||
});
|
||||
|
||||
it('新页面与改造代码严禁包含任何系统 Emoji', () => {
|
||||
const applyPath = path.join(rootDir, 'pwuniapp', 'pages', 'expert', 'apply.vue');
|
||||
const content = fs.readFileSync(applyPath, 'utf-8');
|
||||
const emojiRegex = /(?:\p{Extended_Pictographic}|\p{Emoji_Presentation}|[\u2600-\u27BF])/u;
|
||||
expect(emojiRegex.test(content)).toBe(false);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
||||
在新工单中引用
屏蔽一个用户