Testing a GeoDjango app with a PostGIS database

后端 未结 1 540
日久生厌
日久生厌 2021-01-22 11:10

I am trying to enable testing on a brand new Django app. It has to run geometry tests. My Postgres installation in Postgres.app (with Postgis 2), my default database runs just f

相关标签:
1条回答
  • 2021-01-22 11:57

    Asking the question is answering it ...

    I looked into the Django source, and saw it tests for the existence of template_postgis. If found, it works for Postgis < 2.0. If not found, it works for Postgis >= 2.

    And lo and behold, a relic template_postgis was present in my DB. I renamed it (just keeping it until I'm sure I don't need it for some other project), and the test worked fine.

    0 讨论(0)
提交回复
热议问题