mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Added support to select/deselect objects in the Backup dialog. #642
This commit is contained in:
@@ -37,7 +37,8 @@ describe('BackupSchema', ()=>{
|
||||
},
|
||||
{server: {version: 11000}},
|
||||
pgAdmin.pgBrowser,
|
||||
'backup_objects'
|
||||
'backup_objects',
|
||||
[]
|
||||
);
|
||||
|
||||
it('create object backup', ()=>{
|
||||
@@ -61,6 +62,43 @@ describe('BackupSchema', ()=>{
|
||||
});
|
||||
|
||||
|
||||
let backupSelectedSchemaObj = new BackupSchema(
|
||||
()=> getSectionSchema(),
|
||||
()=> getTypeObjSchema(),
|
||||
()=> getSaveOptSchema({nodeInfo: {server: {version: 11000}}}),
|
||||
()=> getDisabledOptionSchema({nodeInfo: {server: {version: 11000}}}),
|
||||
()=> getMiscellaneousSchema({nodeInfo: {server: {version: 11000}}}),
|
||||
{
|
||||
role: ()=>[],
|
||||
encoding: ()=>[],
|
||||
},
|
||||
{server: {version: 11000}},
|
||||
pgAdmin.pgBrowser,
|
||||
'backup_objects',
|
||||
[{'id': 'public','name': 'public','icon': 'icon-schema', 'children': [{'id': 'public_table','name': 'table','icon': 'icon-coll-table','children': [{'id': 'public_test','name': 'test','icon': 'icon-table','schema': 'public','type': 'table','_name': 'public.test'}],'type': 'table','is_collection': true}],'is_schema': true}]
|
||||
);
|
||||
|
||||
it('create selected object backup', ()=>{
|
||||
mount(<Theme>
|
||||
<SchemaView
|
||||
formType='dialog'
|
||||
schema={backupSelectedSchemaObj}
|
||||
viewHelperProps={{
|
||||
mode: 'create',
|
||||
}}
|
||||
onSave={()=>{/*This is intentional (SonarQube)*/}}
|
||||
onClose={()=>{/*This is intentional (SonarQube)*/}}
|
||||
onHelp={()=>{/*This is intentional (SonarQube)*/}}
|
||||
onDataChange={()=>{/*This is intentional (SonarQube)*/}}
|
||||
confirmOnCloseReset={false}
|
||||
hasSQL={false}
|
||||
disableSqlHelp={false}
|
||||
disableDialogHelp={false}
|
||||
/>
|
||||
</Theme>);
|
||||
});
|
||||
|
||||
|
||||
let backupServerSchemaObj = new BackupSchema(
|
||||
()=> getSectionSchema(),
|
||||
()=> getTypeObjSchema(),
|
||||
@@ -73,7 +111,8 @@ describe('BackupSchema', ()=>{
|
||||
},
|
||||
{server: {version: 11000}},
|
||||
{serverInfo: {}},
|
||||
'server'
|
||||
'server',
|
||||
[]
|
||||
);
|
||||
|
||||
it('create server backup', ()=>{
|
||||
|
||||
Reference in New Issue
Block a user