Efficiently manage and install data fixtures
Project description
[‘Charlatan: Fixtures Made Easyn’, ‘=============================n’, ‘n’, ‘Efficiently manage and install data fixturesn’, ‘n’, ‘Charlatan is a library that you can use in your tests to create databasen’, ‘fixtures. Its aim is to provide a pragmatic interface that focuses on making itn’, ‘simple to define and install fixtures for your tests. It is also agnostic in son’, “far as even though it’s designed to work out of the box with SQLAlchemy models,n”, ‘it can work with pretty much anything else.n’, ‘n’, ‘Documentationn’, ‘————-n’, ‘n’, ‘Latest documentation: uber.github.io/charlatann’, ‘n’, ‘Getting startedn’, ‘—————n’, ‘n’, ‘.. code-block:: pythonn’, ‘n’, ‘ import unittestn’, ‘n’, ‘ from toaster.models import db_sessionn’, ‘n’, ‘ import charlatann’, ‘n’, ‘ charlatan.load(“./tests/data/fixtures.yaml”,n’, ‘ models_package=”toaster.models”,n’, ‘ db_session=db_session)n’, ‘n’, ‘n’, ‘ class TestToaster(unittest.TestCase, charlatan.FixturesManagerMixin):n’, ‘n’, ‘ def setUp(self):n’, ‘ self.clean_fixtures_cache()n’, ‘ self.install_fixtures((“toaster”, “user”))n’, ‘n’, ‘ def test_toaster(self):n’, ‘ “””Verify that toaster can toast.”””n’, ‘n’, ‘ self.toaster.toast()n’, ‘n’, ‘Installationn’, ‘————n’, ‘n’, ‘For now, you need to install charlatan by adding the following to yourn’, ‘requirements.txt::n’, ‘n’, ‘ -e git+git@github.com:uber/charlatan.git#egg=charlatann’, ‘n’, ‘Licensen’, ‘——-n’, ‘n’, ‘charlatan is available under the MIT License.n’, ‘n’, ‘Copyright Uber 2013, Charles-Axel Dein <charles@uber.com>n’, ‘n’, ‘Authorsn’, ‘——-n’, ‘n’, ‘Charles-Axel Dein <charles@uber.com>n’]
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.