Anonymous committed 72c3d65

[svn] couple test additions, whitespace

Comments (0)

Files changed (2)


             radio_button("opinion", "-1") + radio_button("opinion", "1"),
             '<input id="opinion_-1" name="opinion" type="radio" value="-1" /><input id="opinion_1" name="opinion" type="radio" value="1" />'
+        self.assertEqual(
+            radio_button("num_people", 5, selected=True),
+            '<input id="num_people_5" name="num_people" selected="True" type="radio" value="5" />'
+        )
     def test_select(self):
             select("people", "<option>justin</option>"),


 def end_form():
     Outputs "</form>"
+    Example::
+        >>> end_form()
+        '</form>'
     return "</form>"
     Creates a file upload field.
     If you are using file uploads then you will also need to set the multipart option for the form.
+    Example::
+        >>> file_field('myfile')
+        '<input id="myfile" name="myfile" type="file" />'
     return text_field(name, value=value, type="file", **options)
     * ``disable_with`` - The value to be used to rename a disabled version of the submit
     if confirm:
         onclick = options.get('onclick', '')
         if onclick.strip() and not onclick.rstrip().endswith(';'):
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.