Beispiel #1
0
 def __init__(self, headless=True):
     self.web_page = '/vis-js/simple.html'
     self.web_root = Files.path_combine(Files.parent_folder(__file__),
                                        '../web_root')
     self.api_browser = API_Browser(
         headless=headless, auto_close=headless).sync__setup_browser()
     self.render_page = Render_Page(api_browser=self.api_browser,
                                    web_root=self.web_root)
Beispiel #2
0
 def __init__(self, tmp_img=None, clip=None, headless=False):
     self.headless = headless
     self.path_views = Files.path_combine(Files.parent_folder(__file__),
                                          '../../src/web_root')
     self.render_page = Render_Page(headless=self.headless,
                                    auto_close=self.headless,
                                    web_root=self.path_views)
     self.tmp_img = tmp_img
     self.clip = clip
Beispiel #3
0
 def __init__(self, web_page, headless=True):
     self.web_page = web_page
     self.title = 'browser view'
     self.web_root = Files.path_combine(Files.parent_folder(__file__),
                                        '../web_root')
     self.api_browser = API_Browser(
         headless=headless, auto_close=headless).sync__setup_browser()
     self.web_server = Web_Server(self.web_root)
     self.render_page = Render_Page(api_browser=self.api_browser,
                                    web_server=self.web_server)
 def __init__(self):
     self.web_page = '/google_charts/simple.html'
     self.web_root = Files.path_combine(Files.parent_folder(__file__),
                                        '../web_root')
     self.api_browser = API_Browser().sync__setup_browser()
     self.render_page = Render_Page(api_browser=self.api_browser,
                                    web_root=self.web_root)
     self.table_width = '100%'
     self.columns_defs = None
     self.table_title = None
 def __init__(self):
     self.web_page = '/gs/risk/risks-dashboard.html'
     self.web_root = Files.path_combine(Files.parent_folder(__file__),
                                        '../web_root')
     self.headless = False
     self.api_browser = API_Browser(self.headless,
                                    self.headless).sync__setup_browser()
     self.render_page = Render_Page(api_browser=self.api_browser,
                                    web_root=self.web_root)
     self.graph_name = None
     self.jira_key = None
    def setup(self):

        if os.getenv('AWS_REGION'):
            load_dependency('syncer')
            load_dependency('requests')
            #self.setup_AWS()
        # else:
        #     self.setup_local()

        from browser.API_Browser import API_Browser
        from browser.Render_Page import Render_Page
        self.api_browser = API_Browser(
            headless=self.headless,
            auto_close=self.auto_close).sync__setup_browser()
        self.render_page = Render_Page(api_browser=self.api_browser,
                                       web_root=self.web_root())

        return self
 def setUp(self):
     self.render_page  = Render_Page(headless = False, auto_close = False)
     self.random_value = Misc.random_string_and_numbers(6, "dynamic text ")
     self.html         = "<html><script>document.write('{0}')</script></html>".format(self.random_value)