Opened 7 years ago

Last modified 7 years ago

#28572 closed Bug

Form URLField validation fails with valid URL — at Initial Version

Reported by: Jani Tiainen Owned by: nobody
Component: Core (Other) Version: 1.11
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Given valid URL http://myapp:8080/ does not validate as valid url. Happens on 1.8 and 1.11 at least.

# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.test import TestCase
from django import forms

class TestForm(forms.Form):
    url = forms.URLField()

class UrlTestCase(TestCase):

    def test_form(self):
        form = TestForm({'url': 'http://myapp:8080/'})

        self.assertTrue(form.is_valid())

Change History (0)

Note: See TracTickets for help on using tickets.
Back to Top