Exemple #1
0
def main():
    parser = create_parser(); 
    (options, args) = parser.parse_args()
    if not options.infile:
        print "RSpec file not specified"
        return 
        
    rspec = RSpec()
    try:
        rspec.parseFile(options.infile)
    except:
        print "Error reading rspec file"

    if options.tag:
        tag_name = options.tag
        rspec_dicts = rspec.getDictsByTagName(tag_name)
        rspec_dict = {tag_name: rspec_dicts}
    else:
        rspec_dict = rspec.toDict()  
  
    print_dict(rspec_dict, options)

    return
def main():
    r = RSpec()
    r.parseFile(sys.argv[1])
    rspec = r.toDict()
    CreateSliver(None,'plc',rspec,'call-id-plc')