コード例 #1
0
 def run(self, code, capfd, expected_exitcode=0,
         cgi=False, args=[]):
     tmpdir = py.path.local.make_numbered_dir('pyhp')
     phpfile = tmpdir.join(self.tmpname + '.php')
     phpfile.write(code)
     r = main([None, str(phpfile)])
     out, err = capfd.readouterr()
     assert r == expected_exitcode
     assert not err
     return out
コード例 #2
0
ファイル: targetpyhp.py プロジェクト: sasezaki/pyhp
import sys
from rpython.jit.codewriter.policy import JitPolicy
from pyhp.main import main

def target(driver, args):
    driver.exe_name = 'pyhp-c'
    return main, None

def jitpolicy(driver):
    return JitPolicy()

if __name__ == '__main__':
    main(sys.argv)
コード例 #3
0
 def main(self, argv):
     return main(argv)
コード例 #4
0
import sys
from rpython.jit.codewriter.policy import JitPolicy
from pyhp.main import main


def target(driver, args):
    driver.exe_name = 'pyhp-c'
    return main, None


def jitpolicy(driver):
    return JitPolicy()


if __name__ == '__main__':
    main(sys.argv)