TireSwingSoftware / openassign-server

OpenAssign server intended for use by a separate client via RPC
BSD 3-Clause "New" or "Revised" License
6 stars 2 forks source link

failing tests getting unexpected PK #117

Closed mhrivnak closed 12 years ago

mhrivnak commented 12 years ago

These tests are failing for me.

======================================================================
FAIL: test_detailed_exam_view (pr_services.pr_tests.TestAssignmentManagerViews)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/mhrivnak/git/openassign-server/pr_services/pr_tests.py", line 676, in test_detailed_exam_view
    self.assertDictEqual(result[0], expected)
AssertionError: {'status': u'assigned', 'task': {'description': u'', 'title': u'Exam 5', 'passin [truncated]... != {'status': u'assigned', 'task': {'description': u'', 'title': u'Exam 1', 'passin [truncated]...
- {'id': 5,
?        ^

+ {'id': 1,
?        ^

   'status': u'assigned',
   'task': {'description': u'',
-           'id': 5,
?                 ^

+           'id': 1,
?                 ^

-           'name': u'Exam 5',
?                          ^

+           'name': u'Exam 1',
?                          ^

            'passing_score': 70,
-           'title': u'Exam 5',
?                           ^

+           'title': u'Exam 1',
?                           ^

            'type': u'pr_services.exam'},
   'user': {'first_name': u'Primo', 'id': 2, 'last_name': u'Uomo'}}

======================================================================
FAIL: test_exam_view (pr_services.pr_tests.TestAssignmentManagerViews)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/mhrivnak/git/openassign-server/pr_services/pr_tests.py", line 651, in test_exam_view
    self.assertDictEqual(result[0], expected)
AssertionError: {'status': u'assigned', 'task': {'description': u'', 'type': u'pr_services.exam' [truncated]... != {'status': u'assigned', 'task': {'description': u'', 'title': u'Exam 1', 'type': [truncated]...
- {'id': 5,
?        ^

+ {'id': 1,
?        ^

   'status': u'assigned',
   'task': {'description': u'',
-           'id': 5,
?                 ^

+           'id': 1,
?                 ^

-           'name': u'Exam 5',
?                          ^

+           'name': u'Exam 1',
?                          ^

-           'title': u'Exam 5',
?                           ^

+           'title': u'Exam 1',
?                           ^

            'type': u'pr_services.exam'},
   'user': 2}
jc0n commented 12 years ago

Turns out these were related to ordering as well.