mirror of
https://github.com/Syngnat/GoNavi.git
synced 2026-05-12 01:29:42 +08:00
fix(import connect):统一测试用例文案;仅判断mysql-workbench-xml
This commit is contained in:
@@ -1709,7 +1709,7 @@ function App() {
|
||||
try {
|
||||
setPendingConnectionImportPayload(null);
|
||||
const importedViews = await importConnectionsPayload(raw, '');
|
||||
if (importedViews.some(v => !v.hasPrimaryPassword)) {
|
||||
if (importKind === 'mysql-workbench-xml' && importedViews.some(v => !v.hasPrimaryPassword)) {
|
||||
void message.warning(`成功导入 ${importedViews.length} 个连接,部分连接未包含密码,请编辑对应连接并输入密码后保存`);
|
||||
} else {
|
||||
void message.success(`成功导入 ${importedViews.length} 个连接`);
|
||||
|
||||
@@ -39,7 +39,7 @@ describe('connectionModalPresentation', () => {
|
||||
reason: 'saved connection not found: conn-1',
|
||||
fallback: '连接失败',
|
||||
})).toEqual({
|
||||
message: '测试失败: 未找到当前连接对应的已保存密文,请编辑当前连接,并输入密码后保存',
|
||||
message: '测试失败: 未找到当前连接对应的已保存密文,请重新填写密码并保存后再试',
|
||||
shouldToast: true,
|
||||
});
|
||||
});
|
||||
@@ -54,4 +54,4 @@ describe('connectionModalPresentation', () => {
|
||||
shouldToast: false,
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user