#NEWLINE# def test_delete_hanging_domain_1( self ) : #NEWLINE# #INDENT# root_domain = create_fake_zone ( 'foo1.mozilla.com' , suffix = '' ) #NEWLINE# domain_name = root_domain . name #NEWLINE# hang_domain = Domain . objects . create ( name = 'bar.foo1.mozilla.com' ) #NEWLINE# self . assertFalse ( hang_domain . soa ) #NEWLINE# in_domain = Domain . objects . create ( name = 'baz.foo1.mozilla.com' , soa = root_domain . soa ) #NEWLINE# in_domain_name = in_domain . name #NEWLINE# self . assertTrue ( root_domain . has_record_set ( ) ) #NEWLINE# delete_zone_helper ( domain_name ) #NEWLINE# self . assertFalse ( root_domain . has_record_set ( ) ) #NEWLINE# self . assertFalse ( Domain . objects . filter ( name__contains = in_domain_name ) ) #NEWLINE# self . assertTrue ( Domain . objects . filter ( name__contains = root_domain . name ) ) #NEWLINE# self . assertTrue ( Domain . objects . filter ( name__contains = root_domain . name ) )