# Path: core/models.py
# class IndexPage(models.Model):
#     class Meta:
# class HomePage(Page, IndexPage):
#     class Meta:
# class CompanyIndex(Page, IndexPage):
#     class Meta:
# class PageTag(TaggedItemBase):
# class WagtailPage(Page):
#     class Meta:
# class WagtailCompanyPage(WagtailPage):
#     class Meta:
# class WagtailSitePage(WagtailPage):
#     class Meta:
# class SubmitFormField(AbstractFormField):
# class SubmitFormPage(WagtailCaptchaEmailForm if has_recaptcha() else AbstractEmailForm):
#     class Meta:
#     def clean(self):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def og_image(self):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def parent(self):
#     def child(self):
#     def body_text(self):
#     def body_excerpt(self):
#     def og_image(self):
#     def lat(self):
#     def lon(self):
#     def twitter_handler(self):
#     def github_user(self):
#     def children_count(self):
#     def og_image(self):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def sites_count(self):
#     def og_image(self):
#     def __str__(self):
#     def __init__(self, *args, **kwargs):
#     SITES_ORDERING_ALPHABETICAL = 'alphabetical'
#     SITES_ORDERING_CREATED = 'created'
#     SITES_ORDERING_PATH = 'path'
#     SITES_ORDERING = {
#         SITES_ORDERING_PATH: {
#             'name': 'Path (i.e. manual)',
#             'ordering': ['-path'],
#         },
#         SITES_ORDERING_ALPHABETICAL: {
#             'name': 'Alphabetical',
#             'ordering': ['title'],
#         },
#         SITES_ORDERING_CREATED: {
#             'name': 'Created',
#             'ordering': ['-first_published_at'],
#         },
#     }
#     SITES_ORDERING_CHOICES = [
#         (key, opts['name'])
#         for key, opts in sorted(SITES_ORDERING.items(), key=lambda k: k[1]['name'])
#     ]


import core.tests.utils as test_utils
from core import models


class WagtailCompanyPageTestCase(test_utils.WagtailTest):

    def test_twitter_handler(self):
        twitter_user = 'springloadnz'
        twitter_url = 'https://twitter.com/{}'.format(twitter_user)
        twitter_handle = '@{}'.format(twitter_user)


# Path: core/models.py
# class IndexPage(models.Model):
#     class Meta:
# class HomePage(Page, IndexPage):
#     class Meta:
# class CompanyIndex(Page, IndexPage):
#     class Meta:
# class PageTag(TaggedItemBase):
# class WagtailPage(Page):
#     class Meta:
# class WagtailCompanyPage(WagtailPage):
#     class Meta:
# class WagtailSitePage(WagtailPage):
#     class Meta:
# class SubmitFormField(AbstractFormField):
# class SubmitFormPage(WagtailCaptchaEmailForm if has_recaptcha() else AbstractEmailForm):
#     class Meta:
#     def clean(self):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def og_image(self):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def parent(self):
#     def child(self):
#     def body_text(self):
#     def body_excerpt(self):
#     def og_image(self):
#     def lat(self):
#     def lon(self):
#     def twitter_handler(self):
#     def github_user(self):
#     def children_count(self):
#     def og_image(self):
#     def children(self):
#     def get_context(self, request, *args, **kwargs):
#     def sites_count(self):
#     def og_image(self):
#     def __str__(self):
#     def __init__(self, *args, **kwargs):
#     SITES_ORDERING_ALPHABETICAL = 'alphabetical'
#     SITES_ORDERING_CREATED = 'created'
#     SITES_ORDERING_PATH = 'path'
#     SITES_ORDERING = {
#         SITES_ORDERING_PATH: {
#             'name': 'Path (i.e. manual)',
#             'ordering': ['-path'],
#         },
#         SITES_ORDERING_ALPHABETICAL: {
#             'name': 'Alphabetical',
#             'ordering': ['title'],
#         },
#         SITES_ORDERING_CREATED: {
#             'name': 'Created',
#             'ordering': ['-first_published_at'],
#         },
#     }
#     SITES_ORDERING_CHOICES = [
#         (key, opts['name'])
#         for key, opts in sorted(SITES_ORDERING.items(), key=lambda k: k[1]['name'])
#     ]


# Path: core/tests/test_models.py
import core.tests.utils as test_utils
from core import models



class WagtailCompanyPageTestCase(test_utils.WagtailTest):

    def test_twitter_handler(self):
        twitter_user = 'springloadnz'
        twitter_url = 'https://twitter.com/{}'.format(twitter_user)
        twitter_handle = '@{}'.format(twitter_user)


        page = models.WagtailCompanyPage(title='Springload', twitter_url=twitter_url)