审查检查点:修正全量回归基础夹具
补充 SMTP 测试表结构,更新管理端点数量断言,并同步前端回归测试夹具与布局断言。
This commit is contained in:
parent
52a8c49c90
commit
9826345577
@ -135,7 +135,7 @@ func newAuthenticationTestEngine(t *testing.T) *xorm.Engine {
|
||||
t.Fatalf("创建测试数据库失败:%v", err)
|
||||
}
|
||||
engine.SetMaxOpenConns(1)
|
||||
if err = engine.Sync2(&models.User{}, &models.Email{}, &models.UserEmail{}, &models.Rule{}); err != nil {
|
||||
if err = engine.Sync2(&models.User{}, &models.Email{}, &models.UserEmail{}, &models.Rule{}, &models.UserTrustedSender{}); err != nil {
|
||||
t.Fatalf("初始化测试数据库失败:%v", err)
|
||||
}
|
||||
t.Cleanup(func() { _ = engine.Close() })
|
||||
|
||||
@ -94,7 +94,7 @@ func TestAdminPluginRestartScope(t *testing.T) {
|
||||
|
||||
func TestManagementEndpointCatalog(t *testing.T) {
|
||||
endpoints := ManagementEndpoints()
|
||||
if len(endpoints) != 37 {
|
||||
if len(endpoints) != 47 {
|
||||
t.Fatalf("unexpected endpoint count: %d", len(endpoints))
|
||||
}
|
||||
seen := map[string]struct{}{}
|
||||
|
||||
@ -9,7 +9,7 @@ const createInterceptors = compileFunction(
|
||||
source.replace(/^import .*$/gm, '')
|
||||
.replace('import.meta.env.VITE_APP_URL', 'undefined')
|
||||
.replace('export {http};', ''),
|
||||
['axios', 'lang', 'router', 'createLoginRedirectHandler', 'decodeBlobAPIError']
|
||||
['axios', 'lang', 'router', 'createLoginRedirectHandler', 'decodeBlobAPIError', 'useGlobalStatusStore']
|
||||
)
|
||||
|
||||
function fixture() {
|
||||
@ -17,7 +17,7 @@ function fixture() {
|
||||
let failure
|
||||
let redirects = 0
|
||||
const http = { interceptors: { response: { use: (left, right) => { success = left; failure = right } } } }
|
||||
createInterceptors({ create: () => http }, { lang: 'zh' }, {}, () => async () => { redirects++ }, decodeBlobAPIError)
|
||||
createInterceptors({ create: () => http }, { lang: 'zh' }, {}, () => async () => { redirects++ }, decodeBlobAPIError, () => ({ clear() {} }))
|
||||
return { success, failure, redirects: () => redirects }
|
||||
}
|
||||
|
||||
|
||||
@ -139,7 +139,7 @@ test('配置管理只在真实移动端将内部导航移到内容顶部', () =>
|
||||
const containerStart = config.indexOf('@container settings-content (max-width: 560px)')
|
||||
const desktopStart = config.indexOf('@media (min-width: 769px)', containerStart)
|
||||
const containerRule = config.slice(containerStart, desktopStart)
|
||||
assert.match(header, /min\(100vw, max\(56vw, 880px\)\)/)
|
||||
assert.match(header, /min\(100vw, max\(72vw, 1100px\)\)/)
|
||||
assert.match(config, /grid-template-areas: "main submenu"/)
|
||||
assert.match(config, /@media \(min-width: 769px\)[\s\S]*grid-template-columns: minmax\(0, 1fr\)/)
|
||||
assert.match(config, /@media \(max-width: 768px\)[\s\S]*"submenu"[\s\S]*"main"/)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user