def test_json_camelcase():
 test_data = {'under_score': 'values_can', 'be_converted': [{'to_camelcase': 'value'}, 'wont_be_convert']}
 output = hug.output_format.json_camelcase(test_data).decode('utf8')
 assert ('underScore' in output)
 assert ('values_can' in output)
 assert ('beConverted' in output)
 assert ('toCamelcase' in output)
 assert ('value' in output)
 assert ('wont_be_convert' in output)

def test_json_camelcase ( ) : test_data = { 'under_score' : 'values_can' , 'be_converted' : [ { 'to_camelcase' : 'value' } , 'wont_be_convert' ] } output = hug . output_format . json_camelcase ( test_data ) . decode ( 'utf8' ) assert ( 'underScore' in output ) assert ( 'values_can' in output ) assert ( 'beConverted' in output ) assert ( 'toCamelcase' in output ) assert ( 'value' in output ) assert ( 'wont_be_convert' in output )
ensure that its possible to output a hug api method as camelcased json .