#NEWLINE# def test_slug_collision( self ) : #NEWLINE# #INDENT# '\n        Test a slug collision\n        ' #NEWLINE# page_data = self . get_new_page_data ( ) #NEWLINE# superuser = self . get_superuser ( ) #NEWLINE# with self . login_user_context ( superuser ) : #NEWLINE# #INDENT# response = self . client . post ( URL_CMS_PAGE_ADD , page_data ) #NEWLINE# self . assertRedirects ( response , URL_CMS_PAGE ) #NEWLINE# response = self . client . post ( URL_CMS_PAGE_ADD , page_data ) #NEWLINE# self . assertEqual ( response . status_code , 200 ) #NEWLINE# self . assertTrue ( response . request [ 'PATH_INFO' ] . endswith ( URL_CMS_PAGE_ADD ) ) #NEWLINE# self . assertContains ( response , '<ul class="errorlist"><li>Another page with this slug already exists</li></ul>' )