mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-05-01 06:13:59 +00:00
debug print
This commit is contained in:
4
.github/workflows/run-tests-pro.yaml
vendored
4
.github/workflows/run-tests-pro.yaml
vendored
@@ -54,6 +54,10 @@ jobs:
|
|||||||
cd ../dbgate-merged
|
cd ../dbgate-merged
|
||||||
cd e2e-tests
|
cd e2e-tests
|
||||||
yarn test:ci
|
yarn test:ci
|
||||||
|
- name: ls -R
|
||||||
|
run: |
|
||||||
|
cd ../dbgate-merged
|
||||||
|
ls -R
|
||||||
- name: Copy screenshots
|
- name: Copy screenshots
|
||||||
run: |
|
run: |
|
||||||
mkdir screenshots
|
mkdir screenshots
|
||||||
|
|||||||
@@ -1,15 +1,19 @@
|
|||||||
const path = require('path');
|
const path = require('path');
|
||||||
|
|
||||||
|
beforeEach(() => {
|
||||||
|
cy.visit('http://localhost:3000');
|
||||||
|
cy.viewport(1200, 900);
|
||||||
|
});
|
||||||
|
|
||||||
describe('Add connection', () => {
|
describe('Add connection', () => {
|
||||||
it('successfully loads', () => {
|
it('successfully loads', () => {
|
||||||
cy.visit('http://localhost:3000');
|
|
||||||
cy.contains('Database not selected');
|
cy.contains('Database not selected');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('adds connection', () => {
|
it('adds connection', () => {
|
||||||
cy.visit('http://localhost:3000');
|
|
||||||
// cy.get('[data-testid=ConnectionList_buttonNewConnection]').click();
|
// cy.get('[data-testid=ConnectionList_buttonNewConnection]').click();
|
||||||
cy.get('[data-testid=ConnectionDriverFields_connectionType]').select('MySQL');
|
cy.get('[data-testid=ConnectionDriverFields_connectionType]').select('MySQL');
|
||||||
|
cy.screenshot('connection');
|
||||||
cy.get('[data-testid=ConnectionDriverFields_user]').clear().type('root');
|
cy.get('[data-testid=ConnectionDriverFields_user]').clear().type('root');
|
||||||
cy.get('[data-testid=ConnectionDriverFields_password]').clear().type('Pwd2020Db');
|
cy.get('[data-testid=ConnectionDriverFields_password]').clear().type('Pwd2020Db');
|
||||||
cy.get('[data-testid=ConnectionDriverFields_port]').clear().type('16004');
|
cy.get('[data-testid=ConnectionDriverFields_port]').clear().type('16004');
|
||||||
@@ -22,12 +26,10 @@ describe('Add connection', () => {
|
|||||||
// save and connect
|
// save and connect
|
||||||
cy.get('[data-testid=ConnectionTab_buttonSave]').click();
|
cy.get('[data-testid=ConnectionTab_buttonSave]').click();
|
||||||
cy.get('[data-testid=ConnectionTab_buttonConnect]').click();
|
cy.get('[data-testid=ConnectionTab_buttonConnect]').click();
|
||||||
cy.screenshot('add-connection');
|
|
||||||
cy.contains('performance_schema');
|
cy.contains('performance_schema');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('SSH connection - user + password', () => {
|
it('SSH connection - user + password', () => {
|
||||||
cy.visit('http://localhost:3000');
|
|
||||||
cy.contains('Connections');
|
cy.contains('Connections');
|
||||||
|
|
||||||
// cy.realPress('F1');
|
// cy.realPress('F1');
|
||||||
@@ -46,14 +48,12 @@ describe('Add connection', () => {
|
|||||||
cy.get('[data-testid=ConnectionSshTunnelFields_sshLogin]').clear().type('root');
|
cy.get('[data-testid=ConnectionSshTunnelFields_sshLogin]').clear().type('root');
|
||||||
cy.get('[data-testid=ConnectionSshTunnelFields_sshPassword]').clear().type('root');
|
cy.get('[data-testid=ConnectionSshTunnelFields_sshPassword]').clear().type('root');
|
||||||
cy.get('[data-testid=ConnectionSshTunnelFields_sshPort]').clear().type('16006');
|
cy.get('[data-testid=ConnectionSshTunnelFields_sshPort]').clear().type('16006');
|
||||||
cy.screenshot('ssh-tunnel-connection');
|
|
||||||
cy.get('[data-testid=ConnectionTab_buttonSave]').click();
|
cy.get('[data-testid=ConnectionTab_buttonSave]').click();
|
||||||
cy.get('[data-testid=ConnectionTab_buttonConnect]').click();
|
cy.get('[data-testid=ConnectionTab_buttonConnect]').click();
|
||||||
cy.contains('performance_schema');
|
cy.contains('performance_schema');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('SSH connection - keyfile', () => {
|
it('SSH connection - keyfile', () => {
|
||||||
cy.visit('http://localhost:3000');
|
|
||||||
cy.contains('Connections');
|
cy.contains('Connections');
|
||||||
|
|
||||||
// cy.realPress('F1');
|
// cy.realPress('F1');
|
||||||
@@ -82,8 +82,6 @@ describe('Add connection', () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it('ask password - mysql', () => {
|
it('ask password - mysql', () => {
|
||||||
cy.visit('http://localhost:3000');
|
|
||||||
|
|
||||||
cy.get('[data-testid=ConnectionList_buttonNewConnection]').click();
|
cy.get('[data-testid=ConnectionList_buttonNewConnection]').click();
|
||||||
cy.get('[data-testid=ConnectionDriverFields_connectionType]').select('MySQL');
|
cy.get('[data-testid=ConnectionDriverFields_connectionType]').select('MySQL');
|
||||||
cy.get('[data-testid=ConnectionDriverFields_user]').clear().type('root');
|
cy.get('[data-testid=ConnectionDriverFields_user]').clear().type('root');
|
||||||
|
|||||||
@@ -45,6 +45,11 @@ jobs:
|
|||||||
cd e2e-tests
|
cd e2e-tests
|
||||||
yarn test:ci
|
yarn test:ci
|
||||||
|
|
||||||
|
- name: ls -R
|
||||||
|
run: |
|
||||||
|
cd ../dbgate-merged
|
||||||
|
ls -R
|
||||||
|
|
||||||
- name: Copy screenshots
|
- name: Copy screenshots
|
||||||
run: |
|
run: |
|
||||||
mkdir screenshots
|
mkdir screenshots
|
||||||
|
|||||||
Reference in New Issue
Block a user