From 53173ec75d0799c5d2eec97c05055b731996ad47 Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Fri, 28 Jul 2023 23:09:44 -0700 Subject: [PATCH] Fix test execution --- .../db/wisemapping.properties | 5 ++ .../db/wisemapping.script | 46 +++++++++++++++++++ wise-webapp/pom.xml | 6 +-- .../main/webapp/WEB-INF/classes/log4j2.xml | 6 +-- .../test/rest/RestLabelITCase.java | 2 +- 5 files changed, 58 insertions(+), 7 deletions(-) create mode 100644 wise-webapp/${database.base.url}/db/wisemapping.properties create mode 100644 wise-webapp/${database.base.url}/db/wisemapping.script diff --git a/wise-webapp/${database.base.url}/db/wisemapping.properties b/wise-webapp/${database.base.url}/db/wisemapping.properties new file mode 100644 index 00000000..e666a75f --- /dev/null +++ b/wise-webapp/${database.base.url}/db/wisemapping.properties @@ -0,0 +1,5 @@ +#HSQL Database Engine 2.7.1 +#Fri Jul 28 22:57:55 PDT 2023 +modified=yes +tx_timestamp=93 +version=2.7.1 diff --git a/wise-webapp/${database.base.url}/db/wisemapping.script b/wise-webapp/${database.base.url}/db/wisemapping.script new file mode 100644 index 00000000..8cb1d376 --- /dev/null +++ b/wise-webapp/${database.base.url}/db/wisemapping.script @@ -0,0 +1,46 @@ +SET DATABASE UNIQUE NAME HSQLDB89A0348046 +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 93 +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/pom.xml b/wise-webapp/pom.xml index 7bc83645..80a3728d 100644 --- a/wise-webapp/pom.xml +++ b/wise-webapp/pom.xml @@ -474,12 +474,12 @@ jetty-maven-plugin 11.0.15 - foo 8080 9999 FORK + foo ${project.build.directory}/wisemapping.war ${project.basedir}/webdefault.xml @@ -490,11 +490,11 @@ run-forked pre-integration-test - run-war + start-war true - -Ddatabase.base.url=${project.build.directory} -Djetty.port=8080 -Dlogging.level.org.springframework=TRACE + -Ddatabase.base.url=${project.build.directory} -Djetty.port=8080 diff --git a/wise-webapp/src/main/webapp/WEB-INF/classes/log4j2.xml b/wise-webapp/src/main/webapp/WEB-INF/classes/log4j2.xml index 66b2f29f..26b88e6e 100644 --- a/wise-webapp/src/main/webapp/WEB-INF/classes/log4j2.xml +++ b/wise-webapp/src/main/webapp/WEB-INF/classes/log4j2.xml @@ -11,13 +11,13 @@ - + - + - + diff --git a/wise-webapp/src/test/java/com/wisemapping/test/rest/RestLabelITCase.java b/wise-webapp/src/test/java/com/wisemapping/test/rest/RestLabelITCase.java index ab623c02..c4ae1918 100644 --- a/wise-webapp/src/test/java/com/wisemapping/test/rest/RestLabelITCase.java +++ b/wise-webapp/src/test/java/com/wisemapping/test/rest/RestLabelITCase.java @@ -71,7 +71,7 @@ public class RestLabelITCase { static RestLabelList getLabels(HttpHeaders requestHeaders, RestTemplate template) { final HttpEntity findLabelEntity = new HttpEntity(requestHeaders); - final ResponseEntity response = template.exchange(BASE_REST_URL + "/labels", HttpMethod.GET, findLabelEntity, RestLabelList.class); + final ResponseEntity response = template.exchange(BASE_REST_URL + "/labels/", HttpMethod.GET, findLabelEntity, RestLabelList.class); return response.getBody(); }