message: Added CLI Test cases
diff: @@ -11,10 +11,10 @@ export class CLITests {
  @TestCase("dontRequireLuaLib", false)
  @TestCase("rootDir", process.cwd())
  @TestCase("outDir", process.cwd())
  - public defaultOptions(option: string, expected: string) {
  + public defaultOptions(option: any, expected: any) {
  let parsedCommandLine = parseCommandLine([]);
  - Expect(parsedCommandLine.options[option]).toBe(expected);
  + Expect(expected).toBe(parsedCommandLine.options[option]);
  }
  @Test("InvalidLuaTarget")
  @@ -22,4 +22,34 @@ export class CLITests {
  // Don't check error message because the yargs library messes the message up.
  Expect(() => parseCommandLine(['--luaTarget', '42'])).toThrow();
  }
  +
  + @Test("InvalidArgument")
  + public invalidArgument() {
  + // Don't check error message because the yargs library messes the message up.
  + Expect(() => parseCommandLine(['--invalidTarget', 'test'])).toThrow();
  + }
  +
  + @Test("outDir")
  + public outDir() {
  + let parsedCommandLine = parseCommandLine(['--outDir', './test']);
  +
  + Expect(parsedCommandLine.options['outDir']).toBe('./test');
  + }
  +
  + @Test("rootDir")
  + public rootDir() {
  + let parsedCommandLine = parseCommandLine(['--rootDir', './test']);
  +
  + Expect(parsedCommandLine.options['rootDir']).toBe('./test');
  + Expect(parsedCommandLine.options['outDir']).toBe('./test');
  + }
  +
  + @Test("outDirAndRooDir")
  + public outDirAndRooDir() {
  + let parsedCommandLine = parseCommandLine(['--outDir', './testOut', '--rootDir', './testRoot']);
  +
  + Expect(parsedCommandLine.options['outDir']).toBe('./testOut');
  + Expect(parsedCommandLine.options['rootDir']).toBe('./testRoot');
  + }
  +
  }
  