From 00bdf9e9c8d286bf8a7e0ff0da78e526a9aa2901 Mon Sep 17 00:00:00 2001
From: pkupczyk <pkupczyk>
Date: Mon, 15 Dec 2014 10:07:38 +0000
Subject: [PATCH] SSDM-1286 : QGF: Setup of automatic testing of dropboxes -
 fix: java.lang.IllegalArgumentException: Couldn't execute a command:
 [/usr/bin/pg_restore, -U, ci, -d, openbis_test_qgf, -j, 4, -Fc, -O,
 /local0/ci/hudson/gradle/deep_sequencing_unit/resource/test-db/openbis_test_qgf.dmp]
 because: [pg_restore: [archiver (db)] Error while PROCESSING TOC:,
 pg_restore: [archiver (db)] Error from TOC entry 3530; 0 0 COMMENT EXTENSION
 plpgsql , pg_restore: [archiver (db)] could not execute query: ERROR:  must
 be owner of extension plpgsql,     Command was: COMMENT ON EXTENSION plpgsql
 IS 'PL/pgSQL procedural language';, , , , pg_restore: WARNING:  no privileges
 could be revoked for "public", pg_restore: WARNING:  no privileges could be
 revoked for "public", pg_restore: WARNING:  no privileges were granted for
 "public", pg_restore: WARNING:  no privileges were granted for "public",
 WARNING: errors ignored on restore: 1]

SVN: 33051
---
 .../java/ch/systemsx/cisd/openbis/test/server/TestDatabase.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/openbis-common/source/java/ch/systemsx/cisd/openbis/test/server/TestDatabase.java b/openbis-common/source/java/ch/systemsx/cisd/openbis/test/server/TestDatabase.java
index 0622785f380..891075da2b6 100644
--- a/openbis-common/source/java/ch/systemsx/cisd/openbis/test/server/TestDatabase.java
+++ b/openbis-common/source/java/ch/systemsx/cisd/openbis/test/server/TestDatabase.java
@@ -146,7 +146,7 @@ public class TestDatabase
 
         String restore = DumpPreparator.getRestoreExecutable();
         List<String> command =
-                Arrays.asList(restore, "-U", databaseOwner, "-d", databaseName, "-j", "4", "-Fc", "-O",
+                Arrays.asList(restore, "-U", databaseOwner, "-d", databaseName, "-n", "public", "-j", "4", "-Fc", "-O",
                         databaseDump.getAbsolutePath());
         executeCommand(command);
     }
-- 
GitLab