Add ``flask template-test`` command to send template emails with data read from a test file.
Project description
Flask Mail Template Tester
This package provides a faster way to inject data into flask mail templates and send them to a recipient for testing.
Setup
pip install flask-mail-template-tester
pip freeze > requirements.txt
using environment variables (recommended)
export TEMPLATE_DATA_FILE="path/to/some/data.py"
- note: the default data file is set to look at the current working directory + /templates/test_data.py. This is meant to allow you to write a script to test all your templates with one central and standard set of data.
export TEMPLATE_EMAIL="my-email@gmail.com"
flask template-test name-of-template.html
using cli arguments
flask template-test name-of-template.html -d "path/to/some/data.py" -e "my-email@gmail.com"
Release notes
- requires
wheel
&twine
to be installed globally - versioning is handled by autosemver. see docs for that when making more than minor changes
- build package:
python3 setup.py sdist bdist_wheel
- publish package:
twine upload dist/*
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
Built Distribution
Close
Hashes for flask-mail-template-tester-0.3.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | f8228fcaf82dbbedfc845b1006d9a43543857794007341d9c6143c8fc4e21664 |
|
MD5 | 6dfa2a8e1b33de411a95c18fa60016ef |
|
BLAKE2b-256 | 3dec9e3f4460364f8f952f25ea8fa80c39af9fe5511777e9f2478f92d89a6e4d |
Close
Hashes for flask_mail_template_tester-0.3.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fafb38fe4b378e0e20683f0dff4dccff3c16f8c94cca69334e546641e8d04ed9 |
|
MD5 | aede4cba39abdec2325018db0b8bf09d |
|
BLAKE2b-256 | f45b1339fe1dbc9c7d51dd7748f99a11b2fd3269c4f99d3ad7515f57d33fd282 |