"Fossies" - the Fresh Open Source Software Archive

Member "Atom/resources/app/apm/node_modules/node-gyp/gyp/pylib/gyp/generator/xcode_test.py" (8 Mar 2017, 645 Bytes) of archive /windows/misc/atom-windows.zip:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Python source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 #!/usr/bin/env python
    2 
    3 # Copyright (c) 2013 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 """ Unit tests for the xcode.py file. """
    8 
    9 import gyp.generator.xcode as xcode
   10 import unittest
   11 import sys
   12 
   13 
   14 class TestEscapeXcodeDefine(unittest.TestCase):
   15   if sys.platform == 'darwin':
   16     def test_InheritedRemainsUnescaped(self):
   17       self.assertEqual(xcode.EscapeXcodeDefine('$(inherited)'), '$(inherited)')
   18 
   19     def test_Escaping(self):
   20       self.assertEqual(xcode.EscapeXcodeDefine('a b"c\\'), 'a\\ b\\"c\\\\')
   21 
   22 if __name__ == '__main__':
   23   unittest.main()