gyptest-quoting-commands.py 739 B

12345678910111213141516171819202122232425
  1. #!/usr/bin/env python
  2. # Copyright (c) 2012 Google Inc. All rights reserved.
  3. # Use of this source code is governed by a BSD-style license that can be
  4. # found in the LICENSE file.
  5. """
  6. Make sure batch files run as actions. Regression test for previously missing
  7. trailing quote on command line. cmd typically will implicitly insert a missing
  8. quote, but if the command ends in a quote, it will not insert another, so the
  9. command can sometimes become unterminated.
  10. """
  11. import TestGyp
  12. import sys
  13. if sys.platform == 'win32':
  14. test = TestGyp.TestGyp(formats=['msvs', 'ninja'])
  15. CHDIR = 'batch-file-action'
  16. test.run_gyp('batch-file-action.gyp', chdir=CHDIR)
  17. test.build('batch-file-action.gyp', test.ALL, chdir=CHDIR)
  18. test.pass_test()