<s> """<STR_LIT>""" <EOL> from django . test import TestCase <EOL> from seed . utils . generic import split_model_fields <EOL> class DummyClass ( object ) : <EOL> "<STR_LIT>" <EOL> field_one = "<STR_LIT>" <EOL> field_two = "<STR_LIT>" <EOL> class TestGenericUtils ( TestCase ) : <EOL> def test_split_model_fields ( self ) : <EOL> """<STR_LIT>""" <EOL> f1 = '<STR_LIT>' <EOL> f2 = '<STR_LIT>' <EOL> f3 = '<STR_LIT>' <EOL> f4 = '<STR_LIT>' <EOL> obj = DummyClass ( ) <EOL> fields_to_split = [ f1 , f2 , f3 , f4 ] <EOL> obj_fields , non_obj_fields = split_model_fields ( obj , fields_to_split ) <EOL> self . assertEqual ( obj_fields , [ f1 , f2 ] ) <EOL> self . assertEqual ( non_obj_fields , [ f3 , f4 ] ) <EOL> fields_to_split = [ f1 ] <EOL> obj_fields , non_obj_fields = split_model_fields ( obj , fields_to_split ) <EOL> self . assertEqual ( obj_fields , [ f1 ] ) <EOL> self . assertEqual ( non_obj_fields , [ ] ) <EOL> fields_to_split = [ f4 ] <EOL> obj_fields , non_obj_fields = split_model_fields ( obj , fields_to_split ) <EOL> self . assertEqual ( obj_fields , [ ] ) <EOL> self . assertEqual ( non_obj_fields , [ f4 ] ) </s>
