Here are the examples of the python api twisted.internet._dumbwin32proc._findShebang taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
2 Examples
3
Source : test_process.py
with MIT License
from autofelix
with MIT License
from autofelix
def test_findShebang(self):
"""
Look for the string after the shebang C{#!}
in a file.
"""
from twisted.internet._dumbwin32proc import _findShebang
cgiScript = FilePath(b"example.cgi")
cgiScript.setContent(b"#!/usr/bin/python")
program = _findShebang(cgiScript.path)
self.assertEqual(program, "/usr/bin/python")
class Win32CreateProcessFlagsTests(unittest.TestCase):
3
Source : test_process.py
with MIT License
from fbla-competitive-events
with MIT License
from fbla-competitive-events
def test_findShebang(self):
"""
Look for the string after the shebang C{#!}
in a file.
"""
from twisted.internet._dumbwin32proc import _findShebang
cgiScript = FilePath(b"example.cgi")
cgiScript.setContent(b"#!/usr/bin/python")
program = _findShebang(cgiScript.path)
self.assertEqual(program, "/usr/bin/python")
class UtilTests(unittest.TestCase):