This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description
================
MongoDB Test Util
================

This library provides a handful of useful functionality for easing the testing
of systems that rely on *MongoDB* as a datastore

-------------------------
Start and Teardown mongod
-------------------------

For most use cases, you can use this snippet to startup a ``mongod`` instance
for your test environment::

from mongo_test.handlers import startup_handle
startup_handle()

To tear an instance down if one exists::

from mongo_test.handlers import teardown_handle
teardown_handle()

--------
Fixtures
--------

*MongoTest* allows you to specify fixtures in *yaml*, with a few conveniences.
A sample yaml file would look something like::

`user_fixture.yml`
configuration:
collection: users
drop: true
simple_user:
_id: !oid 1
username: idbentley
first_name: Ian
last_name: Bentley

``!oid`` is a custom *yaml* constructor provided by *MongoTest*. This constructor
allows you to create object ids based on an integer seed. You can access the
constructor directly from python, which allows you to write assertions on
document identity::

from mongo_test.fixtures import oid_con
user = db.coll.find({name: 'ian.bentley@gmail.com'})
assert user['_id'] = oid_con(1)

------------------
A complete example
------------------

See the tests for a complete simple example.
Release History

Release History

0.1.2

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
MongoTest-0.1.2.tar.gz (3.7 kB) Copy SHA256 Checksum SHA256 Source Sep 4, 2014

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting