<commit_before>import datetime
import unittest
import json

from application.frontend.frontend import app
from application.frontend.forms import RegistrationForm, ChargeForm
from geo_json_fixtures import valid_geo_json


class FormsTestCase(unittest.TestCase):
    def setUp(self):
        app.config["TESTING"] = True,
        self.app = app
        self.client = app.test_client()

    def test_valid_create_form_with_charge(self):
        with self.app.test_request_context():
            form = RegistrationForm()

            form.title_number.data = "TEST1234"
            form.full_name1.data = "<NAME>"
            form.full_name2.data = "<NAME>"

            form.address_line_1.data = '101 Lake Washington Bldv E'
            form.address_line_2.data = "line2"
            form.address_line_3.data = "line3"
            form.address_line_4.data = "line4"
            form.city.data = "Seattle"
            form.postcode.data = 'SW1A1AA'
            form.country.data = 'GB'

            form.property_tenure.data = "Freehold"
            form.property_class.data = "Absolute"
            form.price_paid.data = "1000000"

            charge_form = ChargeForm()<commit_msg>Fix imports<commit_after>import datetime
import unittest
import json

from application.frontend.frontend import app
from application.frontend.forms import RegistrationForm, ChargeForm, LeaseholdForm
from geo_json_fixtures import valid_geo_json


class FormsTestCase(unittest.TestCase):
    def setUp(self):
        app.config["TESTING"] = True,
        self.app = app
        self.client = app.test_client()

    def test_valid_create_form_with_charge(self):
        with self.app.test_request_context():
            form = RegistrationForm()

            form.title_number.data = "TEST1234"
            form.full_name1.data = "<NAME>"
            form.full_name2.data = "<NAME>"

            form.address_line_1.data = '101 Lake Washington Bldv E'
            form.address_line_2.data = "line2"
            form.address_line_3.data = "line3"
            form.address_line_4.data = "line4"
            form.city.data = "Seattle"
            form.postcode.data = 'SW1A1AA'
            form.country.data = 'GB'

            form.property_tenure.data = "Freehold"
            form.property_class.data = "Absolute"
            form.price_paid.data = "1000000"

            charge_form = ChargeForm()
{'fraction_non_alphanumeric': 0.09465713083718974, 'fraction_numerical': 0.02103491796381994, 'mean_word_length': 2.392296718972896, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '4360040', 'n_tokens_mistral': 741, 'n_tokens_neox': 696, 'n_words': 135}