pgadmin4/web/regression/javascript/schema_ui_files/rule.ui.spec.js

45 lines
1.0 KiB
JavaScript
Raw Normal View History

2021-08-04 05:22:52 -05:00
/////////////////////////////////////////////////////////////
//
// pgAdmin 4 - PostgreSQL Tools
//
2024-01-01 02:43:48 -06:00
// Copyright (C) 2013 - 2024, The pgAdmin Development Team
2021-08-04 05:22:52 -05:00
// This software is released under the PostgreSQL Licence
//
//////////////////////////////////////////////////////////////
2021-08-04 05:22:52 -05:00
import RuleSchema from '../../../pgadmin/browser/server_groups/servers/databases/schemas/tables/rules/static/js/rule.ui';
import {genericBeforeEach, getCreateView, getEditView, getPropertiesView} from '../genericFunctions';
2021-08-04 05:22:52 -05:00
describe('RuleSchema', ()=>{
2021-08-04 05:22:52 -05:00
let schemaObj = new RuleSchema(
{
nodeInfo: {schema: {label: 'public'}, server: {version: 90400}},
nodeData: {label: 'Test'}
},
);
let getInitData = ()=>Promise.resolve({});
2021-08-04 05:22:52 -05:00
beforeEach(()=>{
genericBeforeEach();
2021-08-04 05:22:52 -05:00
});
it('create', async ()=>{
await getCreateView(schemaObj);
2021-08-04 05:22:52 -05:00
});
it('edit', async ()=>{
await getEditView(schemaObj, getInitData);
2021-08-04 05:22:52 -05:00
});
it('properties', async ()=>{
await getPropertiesView(schemaObj, getInitData);
2021-08-04 05:22:52 -05:00
});
});