-
Notifications
You must be signed in to change notification settings - Fork 1
Conversation
@@ -214,9 +214,13 @@ def create_products(count, categories, tags_): | |||
for tag in tags_: | |||
product.tags.add(tag) | |||
|
|||
# group together tags from different tag_groups |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The comment below will be enough. Decide
create_products(count=25, categories=parents[4:], tags_=zipped_tags[0]) | ||
create_products(count=25, categories=parents[5:], tags_=zipped_tags[0]) | ||
# some products should not contain any tag | ||
create_products(count=25, categories=parents[4:4], tags_=[]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
create_products(count=25, categories=parents[4:4], tags_=[]) | |
create_products(count=25, categories=parents[4:5], tags_=[]) |
[4:4]
produces an empty list
|
||
from pages.models import Page | ||
|
||
from stroyprombeton.models import Category, Product | ||
# @todo #320:15m - Do the whole `models` import in tests_selenium |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Import the stroyprombeton.models
package as stb_models
for the whole project.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@artemiy312 , it's too long. I suggest this:
Import 'models' to it's own var
sorting: int=None, | ||
query_string: dict=None, | ||
) -> str: | ||
from urllib.parse import urlencode |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move an import to the top
stroyprombeton/tests/tests_views.py
Outdated
@@ -195,6 +207,25 @@ def test_inactive_product_not_in_category(self): | |||
response = self.client.get(reverse('category', args=(test_product.category_id,))) | |||
self.assertNotIn(test_product, response.context['products']) | |||
|
|||
# @todo #320:60m Take from SE CatalogTags tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What should we take?
8b2d403
to
75cbe72
Compare
Closes #320