Re: [web2py] launch web2py from python interpreter

2015-12-09 Thread Richard Vézina
I guess I will fallback with that solution... It is more fonctional testing... I actually remix Vinicius web2py.test example... Thanks Richard On Tue, Dec 8, 2015 at 3:39 PM, Anthony wrote: > You probably don't want to run tests by making HTTP calls to web2py > running behind a web server (unl

Re: [web2py] launch web2py from python interpreter

2015-12-08 Thread Anthony
You probably don't want to run tests by making HTTP calls to web2py running behind a web server (unless doing functional testing, in which case, just start up the built-in server from the command line and then run your tests -- which you can automate with a shell script). Instead, you can run te

Re: [web2py] launch web2py from python interpreter

2015-12-08 Thread Richard Vézina
I would like to start web2py rocket instance like what we can do with command line python web2py.py -S appname -M, but from python interpreter. So, I can start web2py instance when I launch my test run from my test runner script... So I don't have to make sure there is a web2py instance running an

Re: [web2py] launch web2py from python interpreter

2015-12-08 Thread Massimo Di Pierro
Not sure what you mean. web2py is a collection of pyhton modules. You can import them and use them as any pyhton module. >>> import sys >>> sys.append('/path/to/web2py') >>> from gluon.html import DIV, SPAN >>> print DIV('hello',SPAN('world')) for your convenience we provide a custom shell (lik

[web2py] launch web2py from python interpreter

2015-12-08 Thread Richard
Hello, Is there a way to launch web2py from within python interpreter? Like pytest : https://pytest.org/latest/usage.html#calling-pytest-from-python-code Thanks Richard -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code)