#NEWLINE# def test_create_model_rename_field( self ) : #NEWLINE# #INDENT# '\n        RenameField should optimize into CreateModel.\n        ' #NEWLINE# managers = [ ( 'objects' , EmptyManager ( ) ) ] #NEWLINE# self . assertOptimizesTo ( [ migrations . CreateModel ( name = 'Foo' , fields = [ ( 'name' , models . CharField ( max_length = 255 ) ) ] , options = { #NEWLINE# #INDENT# 'verbose_name' : 'Foo' , #NEWLINE# #UNINDENT# } , bases = ( UnicodeModel , ) , managers = managers ) , migrations . RenameField ( 'Foo' , 'name' , 'title' ) ] , [ migrations . CreateModel ( name = 'Foo' , fields = [ ( 'title' , models . CharField ( max_length = 255 ) ) ] , options = { #NEWLINE# #INDENT# 'verbose_name' : 'Foo' , #NEWLINE# #UNINDENT# } , bases = ( UnicodeModel , ) , managers = managers ) ] )