mirror of
https://framagit.org/la-chariotte/la-chariotte.git
synced 2025-05-02 03:42:26 +02:00
Speedup the tests by using a weaker hash algorythm
This commit is contained in:
parent
b4bdfb8cf4
commit
7373a99aec
3 changed files with 11 additions and 4 deletions
|
@ -37,3 +37,11 @@ def simple_grouped_order(other_user):
|
||||||
grouped_order.save()
|
grouped_order.save()
|
||||||
item = Item.objects.create(name="test item", grouped_order=grouped_order, price=2)
|
item = Item.objects.create(name="test item", grouped_order=grouped_order, price=2)
|
||||||
return grouped_order
|
return grouped_order
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.fixture(autouse=True)
|
||||||
|
def password_hasher_setup(settings):
|
||||||
|
# Use a weaker password hasher during tests, for speed
|
||||||
|
settings.PASSWORD_HASHERS = [
|
||||||
|
"django.contrib.auth.hashers.MD5PasswordHasher",
|
||||||
|
]
|
||||||
|
|
|
@ -1,10 +1,9 @@
|
||||||
import html2text
|
import html2text
|
||||||
|
from django.conf import settings
|
||||||
from django.core import mail
|
from django.core import mail
|
||||||
from django.template.loader import render_to_string
|
from django.template.loader import render_to_string
|
||||||
from django.utils.html import strip_tags
|
from django.utils.html import strip_tags
|
||||||
|
|
||||||
from la_chariotte import settings
|
|
||||||
|
|
||||||
|
|
||||||
def send_order_confirmation_mail(order):
|
def send_order_confirmation_mail(order):
|
||||||
template_name = "mail/order_confirm_mail.html"
|
template_name = "mail/order_confirm_mail.html"
|
||||||
|
|
Loading…
Reference in a new issue