Django

Code

Ticket #6068 (closed: fixed)

Opened 7 months ago

Last modified 7 months ago

typo error in modeltests docstring

Reported by: bartuer <bartuer@exoweb.net> Assigned to: bartuer
Milestone: Component: Uncategorized
Version: SVN Keywords: tests fixtures user-registered management commands
Cc: bartuer@gmail.com Triage Stage: Ready for checkin
Has patch: 1 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

in tests/modeltests, fixture and user_commands are all signed with number 37, this is a typo error.

37.Fixtures. ./fixtures/models.py 37.User-registered management commands ./user_commands/models.py

And all docstring of models.py after number 37 should be changed, they are: tests/modeltests/user_commands/models.py should be 38 tests/modeltests/test_client/models.py should be 39 tests/modeltests/empty/models.py should be 40 tests/modeltests/select_related/models.py should be 41 tests/modeltests/serializers/models.py should be 42

Attachments

6068.diff (2.3 kB) - added by bartuer <bartuer@exoweb.net> on 11/30/07 19:42:09.
sprint-6068.diff (2.2 kB) - added by bartuer on 11/30/07 20:05:55.
this is the right diff
6068.patch (2.2 kB) - added by Wang Chun <wangchun@exoweb.net> on 11/30/07 21:51:16.
no preview in trac, rename and try again…

Change History

11/30/07 19:42:09 changed by bartuer <bartuer@exoweb.net>

  • attachment 6068.diff added.

11/30/07 19:48:50 changed by bartuer <bartuer@exoweb.net>

  • owner changed from nobody to anonymous.
  • needs_better_patch changed.
  • status changed from new to assigned.
  • needs_tests changed.
  • needs_docs changed.

after upload my patch, find the patch has nothing! so I paste it here:

Index: tests/modeltests/select_related/models.py =================================================================== --- tests/modeltests/select_related/models.py (revision 6782) +++ tests/modeltests/select_related/models.py (working copy) @@ -1,5 +1,5 @@

"""

-40. Tests for select_related() +41. Tests for select_related()

select_related() follows all relationships and pre-caches any foreign key values so that complex trees can be fetched in a single query. However, this

Index: tests/modeltests/empty/models.py =================================================================== --- tests/modeltests/empty/models.py (revision 6782) +++ tests/modeltests/empty/models.py (working copy) @@ -1,5 +1,5 @@

"""

-39. Empty model tests +40. Empty model tests

These test that things behave sensibly for the rare corner-case of a model with no fields.

Index: tests/modeltests/serializers/models.py =================================================================== --- tests/modeltests/serializers/models.py (revision 6782) +++ tests/modeltests/serializers/models.py (working copy) @@ -1,6 +1,6 @@

# -*- coding: utf-8 -*- """

-41. Serialization +42. Serialization

django.core.serializers provides interfaces to converting Django querysets to and from "flat" data (i.e. strings).

Index: tests/modeltests/user_commands/models.py =================================================================== --- tests/modeltests/user_commands/models.py (revision 6782) +++ tests/modeltests/user_commands/models.py (working copy) @@ -1,5 +1,5 @@

"""

-37. User-registered management commands +38. User-registered management commands

The manage.py utility provides a number of useful commands for managing a Django project. If you want to add a utility command of your own, you can.

@@ -27,4 +27,4 @@

CommandError?: Unknown command: 'explode'

-"""} \ No newline at end of file +"""} Index: tests/modeltests/test_client/models.py =================================================================== --- tests/modeltests/test_client/models.py (revision 6782) +++ tests/modeltests/test_client/models.py (working copy) @@ -1,6 +1,6 @@

# coding: utf-8 """

-38. Testing using the Test Client +39. Testing using the Test Client

The test client is a class that can act like a simple browser for testing purposes.

11/30/07 19:50:31 changed by bartuer

  • owner changed from anonymous to bartuer.
  • status changed from assigned to new.

11/30/07 19:50:39 changed by bartuer

  • status changed from new to assigned.

11/30/07 19:54:08 changed by bartuer

  • stage changed from Unreviewed to Ready for checkin.

11/30/07 20:05:55 changed by bartuer

  • attachment sprint-6068.diff added.

this is the right diff

11/30/07 21:51:16 changed by Wang Chun <wangchun@exoweb.net>

  • attachment 6068.patch added.

no preview in trac, rename and try again...

12/01/07 15:18:46 changed by mtredinnick

  • status changed from assigned to closed.
  • resolution set to fixed.

(In [6813]) Fixed #6068 -- Updated docstrings in model tests to make the documentation examples correct. Thanks Wang Chun.


Add/Change #6068 (typo error in modeltests docstring)




Change Properties
Action