From 0d95f3b90d07341c09bed598abbf91c7c9f3454c Mon Sep 17 00:00:00 2001 From: collerek Date: Mon, 14 Dec 2020 15:44:12 +0100 Subject: [PATCH] fix for issue 73 - change from text to string - errors in mysql --- tests/test_select_related_with_m2m_and_pk_name_set.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_select_related_with_m2m_and_pk_name_set.py b/tests/test_select_related_with_m2m_and_pk_name_set.py index 36aba19..85cdea6 100644 --- a/tests/test_select_related_with_m2m_and_pk_name_set.py +++ b/tests/test_select_related_with_m2m_and_pk_name_set.py @@ -24,7 +24,7 @@ class Role(ormar.Model): class Meta(MainMeta): pass - name: str = ormar.Text(primary_key=True) + name: str = ormar.String(primary_key=True, max_length=1000) order: int = ormar.Integer(default=0, name="sort_order") description: str = ormar.Text() @@ -33,7 +33,7 @@ class Company(ormar.Model): class Meta(MainMeta): pass - name: str = ormar.Text(primary_key=True) + name: str = ormar.String(primary_key=True, max_length=1000) class UserRoleCompany(ormar.Model): @@ -45,7 +45,7 @@ class User(ormar.Model): class Meta(MainMeta): pass - registrationnumber: str = ormar.Text(primary_key=True) + registrationnumber: str = ormar.String(primary_key=True, max_length=1000) company: Company = ormar.ForeignKey(Company) company2: Company = ormar.ForeignKey(Company, related_name="secondary_users") name: str = ormar.Text()