From 2357101b426573631c989e83a281ba96f116c802 Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Mon, 15 Jan 2024 18:09:01 -0800 Subject: [PATCH] Fix test --- wise-webapp/db/wisemapping.properties | 5 -- wise-webapp/db/wisemapping.script | 46 ------------------- .../com/wisemapping/config/Application.java | 4 +- .../com/wisemapping/dao/LabelManagerImpl.java | 2 +- .../filter/RequestPropertiesInterceptor.java | 5 +- .../java/com/wisemapping/model/Label.java | 1 + .../com/wisemapping/rest/LabelController.java | 8 ++-- .../wisemapping/validator/LabelValidator.java | 1 - .../src/main/resources/application.properties | 30 ++---------- .../src/main/resources/schema-hsqldb.sql | 2 +- .../test/rest/RestLabelITCase.java | 27 ++++++----- .../test/rest/RestMindmapITCase.java | 25 +++++----- 12 files changed, 38 insertions(+), 118 deletions(-) delete mode 100644 wise-webapp/db/wisemapping.properties delete mode 100644 wise-webapp/db/wisemapping.script diff --git a/wise-webapp/db/wisemapping.properties b/wise-webapp/db/wisemapping.properties deleted file mode 100644 index 456f39de..00000000 --- a/wise-webapp/db/wisemapping.properties +++ /dev/null @@ -1,5 +0,0 @@ -#HSQL Database Engine 2.7.1 -#Mon Nov 27 22:17:59 PST 2023 -modified=yes -tx_timestamp=270 -version=2.7.1 diff --git a/wise-webapp/db/wisemapping.script b/wise-webapp/db/wisemapping.script deleted file mode 100644 index 14464be6..00000000 --- a/wise-webapp/db/wisemapping.script +++ /dev/null @@ -1,46 +0,0 @@ -SET DATABASE UNIQUE NAME HSQLDB8C147822D0 -SET DATABASE DEFAULT RESULT MEMORY ROWS 0 -SET DATABASE EVENT LOG LEVEL 0 -SET DATABASE TRANSACTION CONTROL LOCKS -SET DATABASE DEFAULT ISOLATION LEVEL READ COMMITTED -SET DATABASE TRANSACTION ROLLBACK ON CONFLICT TRUE -SET DATABASE TEXT TABLE DEFAULTS '' -SET DATABASE SQL NAMES FALSE -SET DATABASE SQL RESTRICT EXEC FALSE -SET DATABASE SQL REFERENCES FALSE -SET DATABASE SQL SIZE TRUE -SET DATABASE SQL TYPES FALSE -SET DATABASE SQL TDC DELETE TRUE -SET DATABASE SQL TDC UPDATE TRUE -SET DATABASE SQL SYS INDEX NAMES TRUE -SET DATABASE SQL CONCAT NULLS TRUE -SET DATABASE SQL UNIQUE NULLS TRUE -SET DATABASE SQL CONVERT TRUNCATE TRUE -SET DATABASE SQL AVG SCALE 0 -SET DATABASE SQL DOUBLE NAN TRUE -SET FILES WRITE DELAY 500 MILLIS -SET FILES BACKUP INCREMENT TRUE -SET FILES CACHE SIZE 10000 -SET FILES CACHE ROWS 50000 -SET FILES SCALE 32 -SET FILES LOB SCALE 32 -SET FILES DEFRAG 0 -SET FILES NIO TRUE -SET FILES NIO SIZE 256 -SET FILES LOG TRUE -SET FILES LOG SIZE 50 -SET FILES CHECK 270 -SET DATABASE COLLATION "SQL_TEXT" PAD SPACE -CREATE USER SA PASSWORD DIGEST 'd41d8cd98f00b204e9800998ecf8427e' -ALTER USER SA SET LOCAL TRUE -CREATE SCHEMA PUBLIC AUTHORIZATION DBA -ALTER SEQUENCE SYSTEM_LOBS.LOB_ID RESTART WITH 1 -SET DATABASE DEFAULT INITIAL SCHEMA PUBLIC -GRANT USAGE ON DOMAIN INFORMATION_SCHEMA.CARDINAL_NUMBER TO PUBLIC -GRANT USAGE ON DOMAIN INFORMATION_SCHEMA.YES_OR_NO TO PUBLIC -GRANT USAGE ON DOMAIN INFORMATION_SCHEMA.CHARACTER_DATA TO PUBLIC -GRANT USAGE ON DOMAIN INFORMATION_SCHEMA.SQL_IDENTIFIER TO PUBLIC -GRANT USAGE ON DOMAIN INFORMATION_SCHEMA.TIME_STAMP TO PUBLIC -GRANT DBA TO SA -SET SCHEMA SYSTEM_LOBS -INSERT INTO BLOCKS VALUES(0,2147483647,0) diff --git a/wise-webapp/src/main/java/com/wisemapping/config/Application.java b/wise-webapp/src/main/java/com/wisemapping/config/Application.java index ff909d88..82d44a66 100644 --- a/wise-webapp/src/main/java/com/wisemapping/config/Application.java +++ b/wise-webapp/src/main/java/com/wisemapping/config/Application.java @@ -21,8 +21,8 @@ public class Application { new SpringApplicationBuilder() .parent(HibernateConfig.class, ServletConfig.class, CommonConfig.class, SecurityConfig.class).web(WebApplicationType.NONE) - .child(MvcAppConfig.class, MvcSecurityConfig.class, SecurityConfig.class, InterceptorsConfig.class).web(WebApplicationType.SERVLET) - .sibling(RestAppConfig.class, ServletConfig.class, InterceptorsConfig.class).web(WebApplicationType.SERVLET) +// .child(MvcAppConfig.class, MvcSecurityConfig.class, SecurityConfig.class, InterceptorsConfig.class).web(WebApplicationType.SERVLET) + .child(RestAppConfig.class, ServletConfig.class, InterceptorsConfig.class).web(WebApplicationType.SERVLET) .run(args); } diff --git a/wise-webapp/src/main/java/com/wisemapping/dao/LabelManagerImpl.java b/wise-webapp/src/main/java/com/wisemapping/dao/LabelManagerImpl.java index dd6d7472..75139d1b 100644 --- a/wise-webapp/src/main/java/com/wisemapping/dao/LabelManagerImpl.java +++ b/wise-webapp/src/main/java/com/wisemapping/dao/LabelManagerImpl.java @@ -69,7 +69,7 @@ public class LabelManagerImpl final TypedQuery