gyptest-action.py 717 B

1234567891011121314151617181920212223242526
  1. #!/usr/bin/env python
  2. # Copyright (c) 2009 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. Test actions that output to PRODUCT_DIR.
  7. """
  8. import TestGyp
  9. # TODO fix this for xcode: http://code.google.com/p/gyp/issues/detail?id=88
  10. test = TestGyp.TestGyp(formats=['!xcode'])
  11. test.run_gyp('none.gyp', chdir='src')
  12. test.build('none.gyp', test.ALL, chdir='src')
  13. file_content = 'Hello from make-file.py\n'
  14. subdir_file_content = 'Hello from make-subdir-file.py\n'
  15. test.built_file_must_match('file.out', file_content, chdir='src')
  16. test.built_file_must_match('subdir_file.out', subdir_file_content, chdir='src')
  17. test.pass_test()