<commit_before>from datetime import datetime
from django.core.files import File
from django.conf import settings

from armstrong.dev.tests.utils import ArmstrongTestCase
from armstrong.dev.tests.utils.backports import *
from armstrong.dev.tests.utils.concrete import *
from armstrong.dev.tests.utils.users import *

from ..models import Section

import fudge


class ArmSectionsTestCase(ArmstrongTestCase):
    def setUp(self):
        super(ArmSectionsTestCase, self).setUp()
        self.sections = []
        data = [
                ('Local', 'local', 'All about local', None),
                ('Sports', 'sports', 'All about sports', None),
                ('College', 'college', 'All about college sports', 1),
                ('Pro', 'pro', 'All about pro sports', 1),
                ('US', 'us', 'All about US sports', 3),
                ('Weather', 'weather', 'All about weather', None),
                ]
        for title, slug, summary, parent in data:
            if parent is not None:
                parent = self.sections[parent]
            self.sections.append(Section.objects.create(
                    title=title,
                    slug=slug,
                    summary=summary,
                    parent=parent,
                ))<commit_msg>Adjust in a BC way to introduce TestCase<commit_after>from datetime import datetime
from django.core.files import File
from django.conf import settings

from armstrong.dev.tests.utils import ArmstrongTestCase
from armstrong.dev.tests.utils.backports import *
from armstrong.dev.tests.utils.concrete import *
from armstrong.dev.tests.utils.users import *

from ..models import Section

import fudge


class TestCase(ArmstrongTestCase):
    def setUp(self):
        super(ArmSectionsTestCase, self).setUp()
        self.sections = []
        data = [
                ('Local', 'local', 'All about local', None),
                ('Sports', 'sports', 'All about sports', None),
                ('College', 'college', 'All about college sports', 1),
                ('Pro', 'pro', 'All about pro sports', 1),
                ('US', 'us', 'All about US sports', 3),
                ('Weather', 'weather', 'All about weather', None),
                ]
        for title, slug, summary, parent in data:
            if parent is not None:
                parent = self.sections[parent]
            self.sections.append(Section.objects.create(
                    title=title,
                    slug=slug,
                    summary=summary,
                    parent=parent,
                ))


# TODO: Refactor the test cases to remove ArmSectionsTestCase
ArmSectionsTestCase = TestCase
{'fraction_non_alphanumeric': 0.10809792843691149, 'fraction_numerical': 0.0022598870056497176, 'mean_word_length': 2.066974595842956, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3302500', 'n_tokens_mistral': 708, 'n_tokens_neox': 664, 'n_words': 211}