コード例 #1
0
ファイル: ports.py プロジェクト: 0x4d52/JavaScriptCore-X
 def script_shell_command(cls, script_name):
     script_path = cls.script_path(script_name)
     # Win32 does not support shebang. We need to detect the interpreter ourself.
     if sys.platform == 'win32':
         interpreter = Executive.interpreter_for_script(script_path)
         if interpreter:
             return [interpreter, script_path]
     return [script_path]
コード例 #2
0
ファイル: ports.py プロジェクト: InfamousAOKP/external_webkit
 def script_shell_command(cls, script_name):
     script_path = cls.script_path(script_name)
     # Win32 does not support shebang. We need to detect the interpreter ourself.
     if sys.platform == 'win32':
         interpreter = Executive.interpreter_for_script(script_path)
         if interpreter:
             return [interpreter, script_path]
     return [script_path]
コード例 #3
0
ファイル: executive_unittest.py プロジェクト: visnix/WebKit
    def assert_interpreter_for_content(self, intepreter, content):
        fs = MockFileSystem()

        tempfile, temp_name = fs.open_binary_tempfile('')
        tempfile.write(content)
        tempfile.close()
        file_interpreter = Executive.interpreter_for_script(temp_name, fs)

        self.assertEqual(file_interpreter, intepreter)
コード例 #4
0
    def assert_interpreter_for_content(self, intepreter, content):
        fs = MockFileSystem()

        tempfile, temp_name = fs.open_binary_tempfile('')
        tempfile.write(content)
        tempfile.close()
        file_interpreter = Executive.interpreter_for_script(temp_name, fs)

        self.assertEqual(file_interpreter, intepreter)