Gocept.testdb

Latest version: v6.0

Safety actively analyzes 629723 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 3 of 4

1.0

----------------

- Allow a postfix for mysql-commands.

1.0b5

------------------

- Use timestamp for randomizing database names to avoid collisions.

1.0b4

------------------

- `drop-all` entry point now also works, if PostgreSQL or MySQL is not
installed/running.

1.0b3

------------------

- Added `connect` convenience method.

1.0b2

------------------

- Added `is_testing` property as a convenience API.
- Added `exists` property as a convenience API.

1.0b1

------------------

- Changed the protocol for using test databases: separated instantiating a
Database instance from creating the database on the server. Creating
Database instances is cheap now so they can be interacted with and passed
around, deferring the expensive database creation on the server to the
moment db.create() is called explicitly. This is also more symmetric with
respect to db.drop().

- Added functionality for dropping all databases matching the testdb naming
scheme which may have been left on the server by earlier test runs.
Optionally also drops the template db.

- Added option to specify the name of the database for MySQL and PostgreSQL.

- Added an option to specify a template database for PostgreSQL. If it does
not exist, it is created from the specified schema. It is also possible to
force the creation of the template even if it exists (dropping the current
template database). Whenever the schema has changed since the template db
was last created, the template db is updated automatically.

Page 3 of 4

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.