Package openid :: Package test :: Module discoverdata
[frames] | no frames]

Module discoverdata

source code

Module to make discovery data test cases available

Functions
 
getDataName(*components) source code
 
getExampleXRDS() source code
 
readTests(filename) source code
 
getData(filename, name) source code
 
fillTemplate(test_name, template, base_url, example_xrds) source code
 
generateSample(test_name, base_url, example_xrds='<?xml version="1.0" encoding="UTF-8"?>\n<!-- Sample XRDS file..., filename='/Users/willnorris/Projects/openid/python-openid/openid/test/d...) source code
 
generateResult(base_url, input_name, id_name, result_name, success) source code
Variables
  tests_dir = '/Users/willnorris/Projects/openid/python-openid/o...
  data_path = '/Users/willnorris/Projects/openid/python-openid/o...
  testlist = [(True, 'equiv', 'equiv', 'xrds'), (True, 'header',...
  example_xrds = '<?xml version="1.0" encoding="UTF-8"?>\n<!-- S...
  default_test_file = '/Users/willnorris/Projects/openid/python-...
  discover_tests = {}
Variables Details

tests_dir

Value:
'/Users/willnorris/Projects/openid/python-openid/openid/test'

data_path

Value:
'/Users/willnorris/Projects/openid/python-openid/openid/test/data'

testlist

Value:
[(True, 'equiv', 'equiv', 'xrds'),
 (True, 'header', 'header', 'xrds'),
 (True, 'lowercase_header', 'lowercase_header', 'xrds'),
 (True, 'xrds', 'xrds', 'xrds'),
 (True, 'xrds_ctparam', 'xrds_ctparam', 'xrds_ctparam'),
 (True, 'xrds_ctcase', 'xrds_ctcase', 'xrds_ctcase'),
 (False, 'xrds_html', 'xrds_html', 'xrds_html'),
 (True, 'redir_equiv', 'equiv', 'xrds'),
...

example_xrds

Value:
'''<?xml version="1.0" encoding="UTF-8"?>
<!-- Sample XRDS file at: NAME -->
<xrds:XRDS
    xmlns:xrds="xri://$xrds"
    xmlns="xri://$xrd*($v*2.0)">
  <XRD>

    <Service priority="0">
...

default_test_file

Value:
'/Users/willnorris/Projects/openid/python-openid/openid/test/data/test\
1-discover.txt'