#NEWLINE# def test_nodegroup_vlan_segmentation_type( self ) : #NEWLINE# #INDENT# cluster = self . env . create_cluster ( api = False , net_provider = consts . CLUSTER_NET_PROVIDERS . neutron , net_segment_type = consts . NEUTRON_SEGMENT_TYPES . vlan ) #NEWLINE# resp = self . app . post ( reverse ( 'NodeGroupCollectionHandler' ) , json . dumps ( { #NEWLINE# #INDENT# 'cluster_id' : cluster [ 'id' ] , #NEWLINE# 'name' : 'test_ng' , #NEWLINE# #UNINDENT# } ) , headers = self . default_headers , expect_errors = False ) #NEWLINE# self . assertEquals ( resp . status_code , 201 ) #NEWLINE# self . assertEquals ( resp . json_body [ 'cluster_id' ] , resp [ 'id' ] ) #NEWLINE# self . assertEquals ( objects . NodeGroupCollection . get_by_cluster_id ( self . cluster [ 'id' ] ) . count ( ) , 1 )