Skip to main content

c2cgeoportal admin

Project description

# c2cgeoportal_admin

### Checkout

```
git clone git@github.com:camptocamp/c2cgeoportal.git
cd admin
```

### Set up the database
```
sudo -u postgres psql -c "CREATE USER \"www-data\" WITH PASSWORD 'www-data';"

DATABASE=c2cgeoportal
sudo -u postgres psql -c "CREATE DATABASE $DATABASE WITH OWNER \"www-data\";"
sudo -u postgres psql -d $DATABASE -c "CREATE EXTENSION postgis;"
```

Optionally update sqlachemy.url in development.ini or production.ini then:
```
admin/.build/venv/bin/python3 commons/c2cgeoportal_commons/testing/initializedb.py # to create the database
# or
sudo -u postgres psql -d c2cgeoportal -f ./docker/demo-dump.sql # to create and populate the database (demo data)
```

### Run the development web server
```
make serve
```

Open http://localhost:6543/users/

## Run the tests

### Install the selenium chrome driver

https://sites.google.com/a/chromium.org/chromedriver/downloads

### Requires Chrome Version > 65

### Create the test database
```
sudo -u postgres psql -c "CREATE USER \"www-data\" WITH PASSWORD 'www-data';"

DATABASE=geomapfish_tests
sudo -u postgres psql -c "CREATE DATABASE $DATABASE WITH OWNER \"www-data\";"
sudo -u postgres psql -d $DATABASE -c "CREATE EXTENSION postgis;"
```

### Run the tests
```
make test
```

Note that you can run all tests but selenium ones (really fast):
```
.build/venv/bin/pytest -m "not selenium"
```

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

c2cgeoportal_admin-2.3.0.dev22.tar.gz (1.7 kB view details)

Uploaded Source

Built Distribution

File details

Details for the file c2cgeoportal_admin-2.3.0.dev22.tar.gz.

File metadata

File hashes

Hashes for c2cgeoportal_admin-2.3.0.dev22.tar.gz
Algorithm Hash digest
SHA256 98e691e75420783ded6eb0301995123537c5b2556e1d131846b38c4af622aae6
MD5 570d50f7413976771115de84942334da
BLAKE2b-256 c058ed08c4f2ad900fc530a01c40a5b8cf1245f75d9cf28e4d3405c10815d7c9

See more details on using hashes here.

Provenance

File details

Details for the file c2cgeoportal_admin-2.3.0.dev22-py2-none-any.whl.

File metadata

File hashes

Hashes for c2cgeoportal_admin-2.3.0.dev22-py2-none-any.whl
Algorithm Hash digest
SHA256 2b34a16666fc9de7dc6317ffe844d40ac6b7b8f96b76512224b9f99a4dccafa8
MD5 d94eaede327890897dc9ef66f76dbd75
BLAKE2b-256 62f96321444a47f7a8d8b203d414390ae114b7e93348532215d8fa4396c2d37e

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page