IDEMPIERE-5567 Support of UUID for Search (UU) data type (FHCA-4195) (#1787)

* IDEMPIERE-5567 Support of UUID for Search (UU) data type (FHCA-4195) - fix broken unit tests

* - Fix problem with unit test:
MTestTest.testReadingUpdatingTest:65 expected: <Test setting description> but was: <Test setting descriptionMTestEventDelegate>
This commit is contained in:
Carlos Ruiz 2023-04-19 03:07:32 +02:00 committed by GitHub
parent beed782d4e
commit 449c124fe1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 21 additions and 5 deletions

View File

@ -0,0 +1,10 @@
-- IDEMPIERE-5567 Support of UUID on Search (FHCA-4195)
SELECT register_migration_script('202304171928_IDEMPIERE-5567.sql') FROM dual;
SET SQLBLANKLINES ON
SET DEFINE OFF
ALTER TABLE t_selection MODIFY t_selection_uu DEFAULT ' ';
ALTER TABLE t_selection_infowindow MODIFY t_selection_uu DEFAULT ' ';

View File

@ -0,0 +1,7 @@
-- IDEMPIERE-5567 Support of UUID on Search (FHCA-4195)
SELECT register_migration_script('202304171928_IDEMPIERE-5567.sql') FROM dual;
ALTER TABLE t_selection ALTER COLUMN t_selection_uu SET DEFAULT ' ';
ALTER TABLE t_selection_infowindow ALTER COLUMN t_selection_uu SET DEFAULT ' ';

View File

@ -2461,9 +2461,7 @@ public final class DB
if (viewIDValue == null){
insert.append("NULL");
}else{
insert.append("'");
insert.append(viewIDValue);
insert.append("'");
insert.append(DB.TO_STRING(viewIDValue));
}
insert.append(" FROM DUAL ");

View File

@ -62,7 +62,8 @@ public class MTestTest extends AbstractTestCase {
test.setDescription("Test setting description");
test.saveEx();
test.load(trxName);
assertEquals("Test setting description", test.getDescription());
String newDescription = test.getDescription();
assertTrue(newDescription.startsWith("Test setting description"));
MTest testSys = new MTest(ctx, TestInSystem, trxName);
testSys.setDescription("Test setting description");
AdempiereException thrown = assertThrows(