|
|
@@ -742,8 +742,9 @@ def run_ui_tests(context, app, headless=False, parallel=True, with_coverage=Fals |
|
|
|
@click.option('--profile', is_flag=True, default=False) |
|
|
|
@click.option('--noreload', "no_reload", is_flag=True, default=False) |
|
|
|
@click.option('--nothreading', "no_threading", is_flag=True, default=False) |
|
|
|
@click.option('--with-coverage', is_flag=True, default=False) |
|
|
|
@pass_context |
|
|
|
def serve(context, port=None, profile=False, no_reload=False, no_threading=False, sites_path='.', site=None): |
|
|
|
def serve(context, port=None, profile=False, no_reload=False, no_threading=False, sites_path='.', site=None, with_coverage=False): |
|
|
|
"Start development web server" |
|
|
|
import frappe.app |
|
|
|
|
|
|
@@ -751,8 +752,12 @@ def serve(context, port=None, profile=False, no_reload=False, no_threading=False |
|
|
|
site = None |
|
|
|
else: |
|
|
|
site = context.sites[0] |
|
|
|
|
|
|
|
frappe.app.serve(port=port, profile=profile, no_reload=no_reload, no_threading=no_threading, site=site, sites_path='.') |
|
|
|
with CodeCoverage(with_coverage, 'frappe'): |
|
|
|
if with_coverage: |
|
|
|
# unable to track coverage with threading enabled |
|
|
|
no_threading = True |
|
|
|
no_reload = True |
|
|
|
frappe.app.serve(port=port, profile=profile, no_reload=no_reload, no_threading=no_threading, site=site, sites_path='.') |
|
|
|
|
|
|
|
|
|
|
|
@click.command('request') |
|
|
|