Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(4)  |  Call(2)  |  Derive(0)  |  Import(2)

src/d/j/django-shop-simplevariations-0.0.4/shop_simplevariations/tests/simplevariation_tags.py   django-shop-simplevariations(Download)
 
from ..models import OptionGroup
from ..templatetags.simplevariation_tags import get_options, get_option_groups
from .test_utils import create_fixtures
 
    def test01_should_return_all_option_groups_for_a_product(self):
        create_fixtures(options=True)
        product = Product.objects.all()[0]
        option_groups = get_option_groups(product)
        self.assertEqual(len(option_groups), 1)

src/d/j/django-shop-simplevariations-HEAD/shop_simplevariations/tests/simplevariation_tags.py   django-shop-simplevariations(Download)
 
from ..models import OptionGroup
from ..templatetags.simplevariation_tags import get_options, get_option_groups
from .test_utils import create_fixtures
 
    def test01_should_return_all_option_groups_for_a_product(self):
        create_fixtures(options=True)
        product = Product.objects.all()[0]
        option_groups = get_option_groups(product)
        self.assertEqual(len(option_groups), 1)