]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge pull request #660 from mtmail/new-github-URL
authorSarah Hoffmann <lonvia@denofr.de>
Sun, 12 Mar 2017 12:59:11 +0000 (13:59 +0100)
committerGitHub <noreply@github.com>
Sun, 12 Mar 2017 12:59:11 +0000 (13:59 +0100)
github.com/twain47 => github.com/openstreetmap

CONTRIBUTING.md
docs/Import_and_update.md
nominatim/nominatim.h
test/bdd/api/reverse/params.feature
test/bdd/db/import/parenting.feature
test/bdd/steps/db_ops.py

index d23b33928698eeb97975ac0fe4b188856d8acc81..276137f6d9c9b0c8ace6ac8832f42460a46b8d6d 100644 (file)
@@ -38,11 +38,11 @@ The coding style is enforced with PHPCS and can be tested with:
 Before submitting a pull request make sure that the following tests pass:
 
 ```
-  cd tests
-  NOMINATIM_DIR=<builddir> lettuce -t -Fail -t -Tiger features/db features/osm2pgsql
+  cd test/bdd
+  behave -DBUILDDIR=<builddir> db osm2pgsql
 ```
 
 ```
-  cd test-php
+  cd test/php
   phpunit ./
 ```
index 0e58b0f4301011e8f969fedac1ef59973417b476..cd9ff697193fd7e9f8c49703d0df837469ed5614 100644 (file)
@@ -3,7 +3,7 @@ Importing a new database
 
 The following instructions explain how to create a Nominatim database
 from an OSM planet file and how to keep the database up to date. It
-is assumed that you have already sucessfully installed the Nominatim
+is assumed that you have already successfully installed the Nominatim
 software itself, if not return to the [installation page](Installation.md).
 
 Configuration setup in settings/local.php
index 710361995caa853a369bf270559c295b4541690a..a98f3bf946a6456d76586f004a59849ed457c6fe 100644 (file)
@@ -20,7 +20,7 @@ struct output_options
     int expire_tiles_zoom_min;    /* Minimum zoom level for tile expiry list */
     const char *expire_tiles_filename;    /* File name to output expired tiles list to */
     int enable_hstore; /* add an additional hstore column with objects key/value pairs */
-    int enable_multi; /* Output multi-geometries intead of several simple geometries */
+    int enable_multi; /* Output multi-geometries instead of several simple geometries */
     char** hstore_columns; /* list of columns that should be written into their own hstore column */
     int n_hstore_columns; /* number of hstore columns */
 };
index 0d35cdc7f3dbee839824e9c9599a4a4cbd080f7a..765c91c39d3dd5d1885bc0a1071d99ffe74e8b7d 100644 (file)
@@ -1,6 +1,6 @@
 @APIDB
 Feature: Parameters for Reverse API
-    Testing diferent parameter options for reverse API.
+    Testing different parameter options for reverse API.
 
     Scenario Outline: Reverse-geocoding without address
         When sending <format> reverse coordinates 53.603,10.041
index b0b76438f9d377c8167181bffa7fdc3114b5691a..2650f6f06aa3313e57a57b025af8cec872a4324a 100644 (file)
@@ -1,6 +1,6 @@
 @DB
 Feature: Parenting of objects
-    Tests that the correct parent is choosen
+    Tests that the correct parent is chosen
 
     Scenario: Address inherits postcode from its street unless it has a postcode
         Given the scene roads-with-pois
index fa66cd4df260765ce9d44ef676bc556a3a319ec1..869cf829825fce1212ffea6acc437a1cf3266d53 100644 (file)
@@ -243,7 +243,14 @@ def update_place_table(context):
         col.db_insert(cur)
 
     context.db.commit()
-    context.nominatim.run_update_script('index')
+
+    while True:
+        context.nominatim.run_update_script('index')
+
+        cur = context.db.cursor()
+        cur.execute("SELECT 'a' FROM placex WHERE indexed_status != 0 LIMIT 1")
+        if cur.rowcount == 0:
+            break
 
 @when("marking for delete (?P<oids>.*)")
 def delete_places(context, oids):
@@ -254,7 +261,14 @@ def delete_places(context, oids):
         where, params = NominatimID(oid).table_select()
         cur.execute("DELETE FROM place WHERE " + where, params)
     context.db.commit()
-    context.nominatim.run_update_script('index')
+
+    while True:
+        context.nominatim.run_update_script('index')
+
+        cur = context.db.cursor()
+        cur.execute("SELECT 'a' FROM placex WHERE indexed_status != 0 LIMIT 1")
+        if cur.rowcount == 0:
+            break
 
 @then("placex contains(?P<exact> exactly)?")
 def check_placex_contents(context, exact):