<s> """<STR_LIT>""" <EOL> import gyp . generator . ninja as ninja <EOL> import unittest <EOL> import StringIO <EOL> import sys <EOL> import TestCommon <EOL> class TestPrefixesAndSuffixes ( unittest . TestCase ) : <EOL> if sys . platform in ( '<STR_LIT:win32>' , '<STR_LIT>' ) : <EOL> def test_BinaryNamesWindows ( self ) : <EOL> writer = ninja . NinjaWriter ( '<STR_LIT:foo>' , '<STR_LIT>' , '<STR_LIT:.>' , '<STR_LIT:.>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> spec = { '<STR_LIT>' : '<STR_LIT>' } <EOL> self . assertTrue ( writer . ComputeOutputFileName ( spec , '<STR_LIT>' ) . <EOL> endswith ( '<STR_LIT>' ) ) <EOL> self . assertTrue ( writer . ComputeOutputFileName ( spec , '<STR_LIT>' ) . <EOL> endswith ( '<STR_LIT>' ) ) <EOL> self . assertTrue ( writer . ComputeOutputFileName ( spec , '<STR_LIT>' ) . <EOL> endswith ( '<STR_LIT>' ) ) <EOL> if sys . platform == '<STR_LIT>' : <EOL> def test_BinaryNamesLinux ( self ) : <EOL> writer = ninja . NinjaWriter ( '<STR_LIT:foo>' , '<STR_LIT>' , '<STR_LIT:.>' , '<STR_LIT:.>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> spec = { '<STR_LIT>' : '<STR_LIT>' } <EOL> self . assertTrue ( '<STR_LIT:.>' not in writer . ComputeOutputFileName ( spec , <EOL> '<STR_LIT>' ) ) <EOL> self . assertTrue ( writer . ComputeOutputFileName ( spec , '<STR_LIT>' ) . <EOL> startswith ( '<STR_LIT>' ) ) <EOL> self . assertTrue ( writer . ComputeOutputFileName ( spec , '<STR_LIT>' ) . <EOL> startswith ( '<STR_LIT>' ) ) <EOL> self . assertTrue ( writer . ComputeOutputFileName ( spec , '<STR_LIT>' ) . <EOL> endswith ( '<STR_LIT>' ) ) <EOL> self . assertTrue ( writer . ComputeOutputFileName ( spec , '<STR_LIT>' ) . <EOL> endswith ( '<STR_LIT>' ) ) <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> unittest . main ( ) </s>
