Browse Source

Merge pull request #3422 from nocodb/test/screenshot

test: enable screenshots
pull/3428/head
Raju Udava 2 years ago committed by GitHub
parent
commit
346facedc9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      packages/nocodb/src/lib/db/sql-mgr/code/models/xc/ModelXcMetaSqlite.ts
  2. 4
      scripts/cypress-v2/cypress.json
  3. 1
      scripts/cypress-v2/integration/common/00_pre_configurations.js
  4. 2
      scripts/cypress-v2/support/page_objects/navigation.js

3
packages/nocodb/src/lib/db/sql-mgr/code/models/xc/ModelXcMetaSqlite.ts

@ -559,7 +559,8 @@ class ModelXcMetaSqlite extends BaseModelXcMeta {
}
private getAbstractType(col): any {
switch ((col.dt || col.dt).toLowerCase()) {
// remove length value from datatype (for ex. varchar(45) => varchar)
switch (col.dt?.replace(/\(\d+\)$/, '').toLowerCase()) {
case 'date':
return 'date';
case 'datetime':

4
scripts/cypress-v2/cypress.json

@ -19,9 +19,9 @@
"pageLoadTimeout": 600000,
"viewportWidth": 1980,
"viewportHeight": 1000,
"video": false,
"video": true,
"retries": 0,
"screenshotOnRunFailure": false,
"screenshotOnRunFailure": true,
"numTestsKeptInMemory": 0,
"experimentalInteractiveRunEvents": true,
"env": {

1
scripts/cypress-v2/integration/common/00_pre_configurations.js

@ -193,6 +193,7 @@ export const genTest = (apiType, dbType) => {
}
} else {
projectsPage.createProject(proj.basic, proj.config);
cy.wait(5000);
if (dbType === "xcdb") {
// store base URL- to re-visit and delete form view later
let projId;

2
scripts/cypress-v2/support/page_objects/navigation.js

@ -287,7 +287,7 @@ export class _projectsPage {
// }
waitHomePageLoad() {
// cy.url({ timeout: 50000 }).should("contain", "&dbalias=");
cy.url({ timeout: 50000 }).should("contain", "/#/nc/p_");
}
}

Loading…
Cancel
Save