xpcom/tests/TestArguments.cpp
author Shawn Wilsher <me@shawnwilsher.com>
Thu, 03 Feb 2011 12:11:38 -0800
branchGECKO20b9_2011011018_RELBRANCH
changeset 61906 ddf00cef28a3c514756f22046f61b1e31c9bb079
parent 29472 28aa23105a9e238ce28fc7bbbdb5fccc27db325b
child 323280 7011bfbad725d998c408ddf89c01db7d9161eb44
permissions -rw-r--r--
closing old branch that is no longer used per bug 611030

#include <string.h>

int main(int argc, char* argv[]) {
  if (argc != 9)
      return -1;

  if (strcmp("mozilla", argv[1]) != 0)
      return 1;
  if (strcmp("firefox", argv[2]) != 0)
      return 2;
  if (strcmp("thunderbird", argv[3]) != 0)
      return 3;
  if (strcmp("seamonkey", argv[4]) != 0)
      return 4;
  if (strcmp("foo", argv[5]) != 0)
      return 5;
  if (strcmp("bar", argv[6]) != 0)
      return 6;
  if (strcmp("argument with spaces", argv[7]) != 0)
      return 7;
  if (strcmp("\"argument with quotes\"", argv[8]) != 0)
      return 8;
  
  return 0;
}