Home | History | Annotate | Download | only in basics
      1 #!/usr/bin/env python
      2 
      3 # Copyright (c) 2009 Google Inc. All rights reserved.
      4 # Use of this source code is governed by a BSD-style license that can be
      5 # found in the LICENSE file.
      6 
      7 """
      8 Verifies build of an executable in three different configurations.
      9 """
     10 
     11 import TestGyp
     12 
     13 test = TestGyp.TestGyp()
     14 
     15 test.run_gyp('configurations.gyp')
     16 
     17 test.set_configuration('Release')
     18 test.build('configurations.gyp')
     19 test.run_built_executable('configurations', stdout="Release configuration\n")
     20 
     21 test.set_configuration('Debug')
     22 test.build('configurations.gyp')
     23 test.run_built_executable('configurations', stdout="Debug configuration\n")
     24 
     25 test.set_configuration('Foo')
     26 test.build('configurations.gyp')
     27 test.run_built_executable('configurations', stdout="Foo configuration\n")
     28 
     29 test.pass_test()
     30