[glom] LDTP: When creating empty documents, call the initial table 'test_table'
- From: Armin Burgmeier <arminb src gnome org>
- To: svn-commits-list gnome org
- Subject: [glom] LDTP: When creating empty documents, call the initial table 'test_table'
- Date: Fri, 26 Jun 2009 13:37:31 +0000 (UTC)
commit ec2de8e79a79c5effc984b52c2592b00d432f23e
Author: Armin Burgmeier <armin arbur net>
Date: Fri Jun 26 15:32:06 2009 +0200
LDTP: When creating empty documents, call the initial table 'test_table'
* glom/frame_glom.cc
(connection_request_password_and_choose_new_database_name): Remember
the port also for centrally hosted documents when a successful
connection could be made.
* ldtp/database-creation/create-db.py: For empty documents, call the
initial table 'test_table', not 'TestTable', because of bug #587051.
ChangeLog | 10 ++++++++++
glom/frame_glom.cc | 5 ++++-
ldtp/database-creation/create-db.py | 5 +++--
3 files changed, 17 insertions(+), 3 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index ea77bd6..586879d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2009-05-26 Armin Burgmeier <armin openismus com>
+
+ * glom/frame_glom.cc
+ (connection_request_password_and_choose_new_database_name): Remember
+ the port also for centrally hosted documents when a successful
+ connection could be made.
+
+ * ldtp/database-creation/create-db.py: For empty documents, call the
+ initial table 'test_table', not 'TestTable', because of bug #587051.
+
2009-06-26 Armin Burgmeier <armin openismus com>
* glom/dialog_glom.h:
diff --git a/glom/frame_glom.cc b/glom/frame_glom.cc
index 1a90e80..00089f1 100644
--- a/glom/frame_glom.cc
+++ b/glom/frame_glom.cc
@@ -2223,7 +2223,7 @@ bool Frame_Glom::connection_request_password_and_choose_new_database_name()
std::cout << "debug: unused database name found: " << database_name_possible << std::endl;
document->set_connection_database(database_name_possible);
- // Remember host if the document is not self hosted
+ // Remember host and port if the document is not self hosted
#ifdef GLOM_ENABLE_POSTGRESQL
if(document->get_hosting_mode() == Document::HOSTING_MODE_POSTGRES_CENTRAL)
{
@@ -2232,6 +2232,8 @@ bool Frame_Glom::connection_request_password_and_choose_new_database_name()
g_assert(central != NULL);
document->set_connection_server(central->get_host());
+ document->set_connection_port(central->get_port());
+ document->set_connection_try_other_ports(false);
}
// Remember port if the document is self-hosted, so that remote
@@ -2247,6 +2249,7 @@ bool Frame_Glom::connection_request_password_and_choose_new_database_name()
g_assert(self != NULL);
document->set_connection_port(self->get_port());
+ document->set_connection_try_other_ports(false);
}
#endif //GLOM_ENABLE_POSTGRESQL
diff --git a/ldtp/database-creation/create-db.py b/ldtp/database-creation/create-db.py
index 00c0d46..c8a082a 100755
--- a/ldtp/database-creation/create-db.py
+++ b/ldtp/database-creation/create-db.py
@@ -110,9 +110,10 @@ try:
# Create an initial table
click('Tables', 'Add')
# This does not seem to work here, I'm not sure why.
- # getcellvalue works.
+ # getcellvalue works, though:
#setcellvalue('Tables', 'tblTables', 0, 0, 'TestTable')
- generatekeyevent('TestTable<enter>')
+ # Use this as a workaround:
+ generatekeyevent('test_table<enter>')
click('Tables', 'Close')
common.wait_for_database_open()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]