def METHOD_NAME(argv, stdout, environ):
  progname = argv[0]
  optlist, _ = getopt.getopt(argv[1:], "", ["help", "test",])
  testflag = 0
  for (field, _) in optlist:
    if field == "--help":
      usage(progname)
      return
    elif field == "--test":
      testflag = 1
  if testflag:
    test()
    return
  loop()